Follow us on...
Follow us on G+ Follow us on Twitter Follow us on Facebook Watch us on YouTube
Register
Page 6 of 7 FirstFirst ... 4567 LastLast
Results 76 to 90 of 93
  1. #76
    Status
    Offline
    cw-12's Avatar
    Member Senior
    Join Date
    Jan 2010
    Posts
    391
    Reviews
    Read 0 Reviews
    Downloads
    5
    Uploads
    2
    Feedback Score
    0
    Click here to enlarge

    script yang dijalankan, variabel a diisi dengan user dari tool-manager yang uptime-used-nya >= 1m (satu menit)?


    maksudnya apa spt itu? user yang lebih dari 1 menit uptimenya dihapus? berarti kalo user itu uptimenya misal 1jam, nah ini setelah atau sama dengan 1menit dihapus dong?

  2. #77
    Status
    Offline
    coco_nk4l's Avatar
    Member
    Join Date
    Aug 2009
    Location
    Tanjung Duren - Jakarta Barat
    Posts
    136
    Reviews
    Read 0 Reviews
    Downloads
    3
    Uploads
    2
    Feedback Score
    0
    Masalah variable itu kan bisa di ganti.. uptime-used=0 juga jalan yg penting kan variablenya jalan Gan..
    kalo itu mah buat tester aja,, itu abis tes generate user dengan waktu 5 menit trs aq coba hapus user yg udah kepakai, krana saya asumsikan vocer akan kadaluarsa dalam waktu 1hari entah itu uptime-use masi 1 jam ato bahkan masi 2jam asal dy abis login berarti kan akan di hapus, masalah Variable itu tinggal kita kreatif aja
    yang penting Jawabannya SCRIPT ITU BISA UNTUk V.5.x

  3. #78
    Status
    Offline
    cw-12's Avatar
    Member Senior
    Join Date
    Jan 2010
    Posts
    391
    Reviews
    Read 0 Reviews
    Downloads
    5
    Uploads
    2
    Feedback Score
    0
    Click here to enlarge Originally Posted by coco_nk4l Click here to enlarge
    Masalah variable itu kan bisa di ganti.. uptime-used=0 juga jalan yg penting kan variablenya jalan Gan..
    kalo itu mah buat tester aja,, itu abis tes generate user dengan waktu 5 menit trs aq coba hapus user yg udah kepakai, krana saya asumsikan vocer akan kadaluarsa dalam waktu 1hari entah itu uptime-use masi 1 jam ato bahkan masi 2jam asal dy abis login berarti kan akan di hapus, masalah Variable itu tinggal kita kreatif aja
    yang penting Jawabannya SCRIPT ITU BISA UNTUk V.5.x
    iya, itu memang jalan gan, udah dicoba.
    cuman yang jadi soal, bila punya banyak voucher misal 1jam, 2jam, 3jam dan seterusnya.
    berarti harus banyak script dong.

    di v.4.17 kita bisa pakai param credit-left. di versi 5.x gak bisa.

    cmiiw.

  4. #79
    Status
    Offline
    coco_nk4l's Avatar
    Member
    Join Date
    Aug 2009
    Location
    Tanjung Duren - Jakarta Barat
    Posts
    136
    Reviews
    Read 0 Reviews
    Downloads
    3
    Uploads
    2
    Feedback Score
    0
    Click here to enlarge Originally Posted by cw-12 Click here to enlarge
    iya, itu memang jalan gan, udah dicoba.
    cuman yang jadi soal, bila punya banyak voucher misal 1jam, 2jam, 3jam dan seterusnya.
    berarti harus banyak script dong.

    di v.4.17 kita bisa pakai param credit-left. di versi 5.x gak bisa.

    cmiiw.
    Lho berarti yang Kemaren Bilang gag Work belum di Coba donk???? Click here to enlarge
    kalo masalah Vocer itu tinggal Parameter uptime-usednya ajaaa....

  5. #80
    Status
    Offline
    dubkorq's Avatar
    Newbie
    Join Date
    May 2010
    Posts
    28
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    Ohh.... MT mu Wes DiUpgrade 5.xx thoh ??
    Piye.... mangle Dan kawan2 ono sing bedho ga ??

    Wehhh menggila koe ... ^_^

  6. #81
    Status
    Offline
    coco_nk4l's Avatar
    Member
    Join Date
    Aug 2009
    Location
    Tanjung Duren - Jakarta Barat
    Posts
    136
    Reviews
    Read 0 Reviews
    Downloads
    3
    Uploads
    2
    Feedback Score
    0
    Sampun Gan....
    Untuk Mangle gag ada masalah Konfig yg lama Masih Jalan dengan Sempurna,,,

  7. #82
    Status
    Offline
    butt's Avatar
    Newbie
    Join Date
    Jul 2009
    Posts
    51
    Reviews
    Read 0 Reviews
    Downloads
    2
    Uploads
    0
    Feedback Score
    0
    mau nanya agan2... kalau kita hapus user yang expirednya berdsarkan tanggal(end time) bisa ngak ya gan ?? misalnya ada 3 buah voucher yang jatah expirednya sama2 satu bulan... jadi jika end timenya - start timenya = 30 hari maka user tersebut di hapus... mohon pencerahannya gan...

  8. #83
    Status
    Offline
    butt's Avatar
    Newbie
    Join Date
    Jul 2009
    Posts
    51
    Reviews
    Read 0 Reviews
    Downloads
    2
    Uploads
    0
    Feedback Score
    0
    Click here to enlarge Originally Posted by butt Click here to enlarge
    mau nanya agan2... kalau kita hapus user yang expirednya berdsarkan tanggal(end time) bisa ngak ya gan ?? misalnya ada 3 buah voucher yang jatah expirednya sama2 satu bulan... jadi jika end timenya - start timenya = 30 hari maka user tersebut di hapus... mohon pencerahannya gan...
    Click here to enlarge ngak ada yg jawab Click here to enlarge

  9. #84
    Status
    Offline
    lazyshark's Avatar
    Baru Gabung
    Join Date
    May 2010
    Posts
    16
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    Click here to enlarge Originally Posted by coco_nk4l Click here to enlarge
    Ne buat admin Hotspot yang masih manual hapusin User hotspotnya 1 per 1 Click here to enlarge
    Code:
    :foreach a in=[/tool user-manager user find] do={:if ([/tool user-manager user get $a uptime-used]=0s) do={
    :log warning ("deleted Expired user.. $[/tool user-manager user get $a name]")
    /tool user-manager user remove [/tool user-manager user get $a name] 
    }}
    nah kalo script di atas udah di set tinggal atur schedulenya aja gan,,,
    Click here to enlarge
    Script di atas bisa di modif sesuai kebutuhan

    mantabs..secangkir kopi jahe buat agan Click here to enlargeClick here to enlargeClick here to enlarge

  10. #85
    Status
    Offline
    Xerophie's Avatar
    Calon Member
    Join Date
    Sep 2007
    Location
    Recycle Bin
    Posts
    84
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    1 (100%)
    Thanks gan... lagi butuh nihhh... Click here to enlarge

  11. #86
    Status
    Offline
    jalurnet's Avatar
    Baru Gabung
    Join Date
    Mar 2010
    Posts
    11
    Reviews
    Read 0 Reviews
    Downloads
    7
    Uploads
    0
    Feedback Score
    0
    cobain yg ini gan, masalah kita same. tapi belum ketemu jawaban yang pas
    # Date: 03/06/2011
    # Author: Alfredo Agius
    # File: cleanUserManager
    # Tested on: RouterOS version 3.xx
    #
    # Description: Deletes Mikrotik User-Manager accounts whos credit-till-time is less than today's date.
    # Accounts which are not yet activated are skipped.
    # A summary of all accounts skipped, deleted and kept is displayed in the end of the cycle to
    # console screen and to log.
    #
    # Disclaimer: Use this script at your own risk.
    # This script has been throughly tested on three (3) v3.xx RouterBoards and didn't materialise
    # any problems. However, I am not responsible for any damage and/or data loss that might happen
    # to your User-Manager database. It's your responsibility to backup any data before testing any
    # script on a live system.
    #
    # Important: !! MAKE SURE THAT YOUR CLOCK DATE IS SET CORRECTLY, AS THIS SCRIPT USES IT AS REFERENCE !!
    #
    # Notes: This script can be run either from WinBox or from console.
    # -- If console is used, all processing details will be shown, and a summary of operations in the end.
    # -- If WinBox is used, all processing details will be HIDDEN, and a summary of operations will be
    # sent to log.
    #
    # Script can be run manually or on a schedule. !!Please note that it's processor intensive!!
    #
    # Install: In Winbox, go to System > Script, create a new script, name it cleanUserManager and paste
    # this whole document in it. Click Apply and OK.
    #
    # Syntax: To run the script, from terminal enter "/system script run cleanUserManager" without quotes, or run from WinBox.

    :global iterator 0
    :global deleted 0
    :global skipped 0
    :global kept 0
    /tool user-manager user print brief without-paging
    :global counter [/tool user-manager user print count-only]

    :do {

    :local thisDate
    :local thisYear
    :local thisDay
    :local thisMonth
    :local thisCredit
    :local creditYear
    :local creditDay
    :local creditMonth
    :local creditName

    :set thisDate [/system clock get date]

    :set thisYear [Click here to enlargeick $thisDate 7 11]
    :set thisDay [Click here to enlargeick $thisDate 4 6]
    :set thisMonth [Click here to enlargeick $thisDate 0 3]

    :if ($thisMonth="jan") do { :set thisMonth "01"}
    :if ($thisMonth="feb") do { :set thisMonth "02"}
    :if ($thisMonth="mar") do { :set thisMonth "03"}
    :if ($thisMonth="apr") do { :set thisMonth "04"}
    :if ($thisMonth="may") do { :set thisMonth "05"}
    :if ($thisMonth="jun") do { :set thisMonth "06"}
    :if ($thisMonth="jul") do { :set thisMonth "07"}
    :if ($thisMonth="aug") do { :set thisMonth "08"}
    :if ($thisMonth="sep") do { :set thisMonth "09"}
    :if ($thisMonth="oct") do { :set thisMonth "10"}
    :if ($thisMonth="nov") do { :set thisMonth "11"}
    :if ($thisMonth="dec") do { :set thisMonth "12"}

    :local thisCredit [/tool user-manager user get $iterator credit-till-time]

    :set creditYear [Click here to enlargeick $thisCredit 7 11]
    :set creditDay [Click here to enlargeick $thisCredit 4 6]
    :set creditMonth [Click here to enlargeick $thisCredit 0 3]

    :set creditName [/tool user-manager user get $iterator name]

    :if ($creditMonth="jan") do { :set creditMonth "01"}
    :if ($creditMonth="feb") do { :set creditMonth "02"}
    :if ($creditMonth="mar") do { :set creditMonth "03"}
    :if ($creditMonth="apr") do { :set creditMonth "04"}
    :if ($creditMonth="may") do { :set creditMonth "05"}
    :if ($creditMonth="jun") do { :set creditMonth "06"}
    :if ($creditMonth="jul") do { :set creditMonth "07"}
    :if ($creditMonth="aug") do { :set creditMonth "08"}
    :if ($creditMonth="sep") do { :set creditMonth "09"}
    :if ($creditMonth="oct") do { :set creditMonth "10"}
    :if ($creditMonth="nov") do { :set creditMonth "11"}
    :if ($creditMonth="dec") do { :set creditMonth "12"}

    :if ([:len $thisCredit]!=0) do {
    :if ($creditYear>$thisYear) do {
    Click here to enlargeut {"Kept username ".$creditName." which expires on ".$thisCredit }; :set kept ($kept+1)} else {:if ($creditYear<$thisYear) do {
    /tool user-manager user remove $creditName; Click here to enlargeut {"Deleted username ". $creditName . " which expired on " . $thisCredit}; :set deleted ($deleted+1)} else {:if ($creditMonth>$thisMonth) do {
    Click here to enlargeut {"Kept username " . $creditName . " which expires on " . $thisCredit}; :set kept ($kept+1)} else {:if ($creditMonth<$thisMonth) do {
    /tool user-manager user remove $creditName; Click here to enlargeut {"Deleted username ". $creditName . " which expired on " . $thisCredit}; :set deleted ($deleted+1)} else {:if ($creditDay>=$thisDay) do {
    Click here to enlargeut {"Kept username " . $creditName . " which expires on " . $thisCredit}; :set kept ($kept +1)} else {/tool user-manager user remove $creditName; Click here to enlargeut {"Deleted username ". $creditName . " which expired on " . $thisCredit}; :set deleted ($deleted+1)}
    }
    }
    }
    }
    } else {Click here to enlargeut {"Username ". $creditName . " is not yet activated. Skipping ..."}; :set skipped ($skipped+1)}
    :set iterator ($iterator+1)} while=($iterator!=$counter)

    Click here to enlargeut {"\n\n\r==============================\n\n\rCleani ng ready!\n\n\rPerformed these operations:\n\r\t"}
    Click here to enlargeut {"Records processed: \t" . $counter}
    Click here to enlargeut {"\n\rDeleted usernames: \t" . $deleted}
    Click here to enlargeut {"Skipped usernames: \t" . $skipped}
    Click here to enlargeut {"Kept usernames: \t\t" . $kept}
    Click here to enlargeut {"\n\r==============================\n\r"}

    :log info ("\n\r==============================\n\n\rClean ing ready!\n\n\rPerformed these operations:\n\r\t")
    :log info ("Records processed: \t" . $counter)
    :log info ("\n\rDeleted usernames: \t" . $deleted)
    :log info ("Skipped usernames: \t" . $skipped)
    :log info ("Kept usernames: \t\t" . $kept)
    :log info ("\n\r==============================\n\r")

    # END OF FILE
    Ud di coba di v.5+ g berhasil
    ada yang bisa ngembangin gan?

  12. #87
    Status
    Offline
    aura_hotspot's Avatar
    Baru Gabung
    Join Date
    Mar 2011
    Location
    Jayapura-Papua
    Posts
    7
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    Ne buat admin Hotspot yang masih manual hapusin User hotspotnya 1 per 1
    Code:

    :foreach a in=[/tool user-manager user find] do={:if ([/tool user-manager user get $a uptime-used]=0s) do={
    :log warning ("deleted Expired user.. $[/tool user-manager user get $a name]")
    /tool user-manager user remove [/tool user-manager user get $a name]
    }}

    Scrip ini bisa berjalan di V. 5.14 g y?

  13. #88
    Status
    Offline
    uchuts's Avatar
    Baru Gabung
    Join Date
    Feb 2012
    Location
    makassar
    Posts
    10
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    setelah keliling" untuk cari cara untuk hapus otomatis user expired di userman OS 5.XX tidak ketemu-ketemu,
    jadi mau ga mau rela ga rela sudi ga sudi masih ada jalan menuju roma,, paling nggak lumayan mempermudah tapi ga semudah pake script,,,

    userman - advanced search
    Penampakan>>> Click here to enlarge

    lumayan costom sih ... CMIWW Click here to enlarge
    Last edited by uchuts; 21-01-2013 at 01:50.

  14. The Following 2 Users Say Thank You to uchuts For This Useful Post:


  15. #89
    Status
    Offline
    Adhiefree's Avatar
    Member
    Join Date
    Nov 2010
    Posts
    183
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    klu yang ini kan menurut uptime used,sedangkan kalau menurut aktual profile gimana gan?

  16. #90
    Status
    Offline
    dna765mb's Avatar
    Baru Gabung
    Join Date
    Oct 2012
    Posts
    6
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    pantes ane coba beberapa scrip di versi 5.25 nggak mau ternyata belum support to..... ada sudah update script belum?

 

 
Page 6 of 7 FirstFirst ... 4567 LastLast

Thread Information

Users Browsing this Thread

There are currently 2 users browsing this thread. (0 members and 2 guests)

Similar Threads

  1. Delete User on user-manager
    By yanbali in forum HotSpot, The Dude & User Manager
    Replies: 14
    Last Post: 26-07-2014, 18:50
  2. How to setting : Hotspot user expired
    By mgunawan in forum Beginner Basics
    Replies: 6
    Last Post: 25-09-2010, 23:44
  3. script User Hotspot
    By deska in forum Scripting @ Mikrotik
    Replies: 7
    Last Post: 19-07-2009, 21:37
  4. Replies: 3
    Last Post: 04-10-2008, 14:53
  5. Replies: 12
    Last Post: 11-04-2008, 08:28

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •