comet424 Posted February 17, 2019 Share Posted February 17, 2019 (edited) hi I tried googling and I got confused with this suduo command line etc In windows all I have to do is right click and choose the file to connect but I wanna use open vpn in a script.. so it connects then pauses my script stuff for 1 minute so gives time open vpn connects and then runs script and then lastly script tells OpenVPN to disconnect the connection.. and lastly does script files offer IF ElseIF statements.... so If OpenVPN connection failes do not try to run the script and retry 3 times then forget it... elseif then run the script but for the commandline would it be line "OpenVPN scriptfile -connect" and "OpenVPN scriptifile -disconnect" I know I asked last year similar but I couldn't find my old question and I needed commandline not the gui version.. so sorry for reasking same questions soo basically I wanna write the script like this OpenVPN <config file> -connect x=0 do if OpenVPN(configfile) = connect then pause 1 min <script stuff I want done> OpenVPN <config file> -disconnect exit do elseif then x=x+1 OpenVPN <config file> -connect if x=>3 then exitdo (if it cant connect 3 times just exit and quit the script file) endif loop that's something id like it to do if its possible Edited February 18, 2019 by comet424 Quote Link to comment
comet424 Posted February 19, 2019 Author Share Posted February 19, 2019 and is there a pluggin that shows the speed of file transfers from unraid to unraid.. as id like to know how fast rsync is copying I tried network stats the 3 plugins.. network stats only one that shows up but doesn't do second by second and the other 2 fail to start Quote Link to comment
JorgeB Posted February 19, 2019 Share Posted February 19, 2019 6 hours ago, comet424 said: as id like to know how fast rsync is copying use rsync --progress Quote Link to comment
comet424 Posted February 19, 2019 Author Share Posted February 19, 2019 (edited) ya I tried that that doesn't actually show live its not like windows showing second to second 50mb/s all it showed was 50k/s when the file transfer is done..and then states it only took 0 seconds to complete when it took a minute or so ... but I looking for live second by second and since no one can help me with the OpenVPN or if the IF ELSE statements in rysnc is there a way to include it in 1.. do not rsynic .recyclinbin and 2.. give "new persmissions" to the backup server... as I have to each time after running rsync run "New Permissions" under Tools since I don't have administrator access.. Edited February 19, 2019 by comet424 Quote Link to comment
JorgeB Posted February 19, 2019 Share Posted February 19, 2019 21 minutes ago, comet424 said: ya I tried that that doesn't actually show live its not like windows showing second to second 50mb/s all it showed was 50k/s when the file transfer is done..and then states it only took 0 seconds to complete when it took a minute or so ... but I looking for live second by second Works fine for me. Quote Link to comment
comet424 Posted February 19, 2019 Author Share Posted February 19, 2019 ya not for me it will say 0:00:00 like that for the time and 6.74 kbs but maybe its because im running it as a background script and I noticed no way to see file transferring like windows does when you copy or move a file second by second speed rate guess I can live without it or find some other plugin.. now I just gotta figure how to OpenVPN in 1 line and get rsynic not to keep syncing recycling bin.. and give administrator rights since its not doing it one of these days it will work perfect for me just not today lol Quote Link to comment
itimpi Posted February 19, 2019 Share Posted February 19, 2019 1 hour ago, comet424 said: but maybe its because im running it as a background script and I noticed no way to see file transferring like windows does when you copy or move a file second by second speed rate Have you tried running it in the foreground? When doing that you get real-time reporting on the progress from rsync with the —progress option. Quote Link to comment
comet424 Posted February 19, 2019 Author Share Posted February 19, 2019 no I tried the command line in terminal as I found out couple times if you don't run the command line in Webterminal… Rsync gives error 255 in the script so I've on done the command line to get it started and then just background heck if possible id like it to just report instead of file names display 55% rysncing done speed is 80mb/s say as freenas gave a percentage done for rsync that's what I wouldn't mind seeing just like "Percent Done 58% Speed 45mb/s" as a running total for rsync my other issues I asked for ill try googling other websites for answers Quote Link to comment
comet424 Posted February 22, 2019 Author Share Posted February 22, 2019 bump "on the issue of the IF ELSE Statements" forget the OpenVPN guess that's a new thread as that locks me out of unraid Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.