Unfortunately no one can be told what fun_plug is - you have to see it for yourself.
You are not logged in.
Hi,
Thanks for the guide, it's really helpful. But, I am wondering if anyone can help me to apply the exact same method to syncing a folder on a local computer to the DNS.
I tried to modify the code, but it seems like ssh is needed. and my local computer would be "192.168.xx.xx:/userdata" in the rsync command line, and this is the error I get: I didn't put a user in front of the source folder. Not sure if one was needed.
rsync: Failed to exec ssh: No such file or directory (2)
rsync error: error in IPC code (code 14) at pipe.c(86) [receiver=2.6.9]
rsync: writefd_unbuffered failed to write 4 bytes [receiver]: Broken pipe (32)
rsync error: error in IPC code (code 14) at io.c(1122) [receiver=2.6.9]
Last edited by redmodel (2007-12-27 04:00:50)
Offline
I also had a lot of trouble getting rsync for Windows running. I downloaded cwRsync but it seems to need Cygwin to run properly. I tried to use rsync like this from the command line in Windows:
rsync -Dlrtpv --delete e:\data p:\backup
where e:\ is my local harddisk and p:\ is the Samba share of the NAS. It didn't work because rsync obviously assumes that locations containing a ":" are remote. As not both, source and target can be remote locations, it failed doing the sync.
At last I wrote a small Python script doing similar work. Of course, it is not capable of doing all the stuff rsync can do and it is also not that band width efficient but it simply copies newer files from SRC to DST and removes files from DST that have been deleted on SRC. I use it als GroupPolicy / Logoff Script on Windows to back up all modified files to the NAS when logging off or switching off the computer.
If you're interested, its in the attachment.
Bernhard
Last edited by bgoedel (2007-12-27 16:17:46)
Offline
Okay, i gave up on getting the rsync client on the DNS to connect to my local computer to do backup...
I just enabled the Rsync Server on the DNS and added a user:pass to the rsyncd.secret file
Then, I installed this on my computer:
http://www.aboutmyip.com/AboutMyXApp/DeltaCopy.jsp
Only ran the client, and it successfully found the Rsync Server on the DNS, and now syncing works perfectly. DeltaCopy works very well with Windows Scheduler. Of course, i would have liked the DNS to do all the work, but DeltaCopy runs nicely in the background.. not a big deal, and has a GUI.
Last edited by redmodel (2007-12-28 02:50:03)
Offline
I wrote a set of scripts to do what you're talking about--where the DNS-323 does all the work to do the backups. It's available at http://backupnetclone.sourceforge.net/ The files are there, but I don't have installation instructions yet. Not sure when I'll get the instructions up, but the basics are there.
Offline
Chumby,
Thanks for this - it's fantastic. A much safer alternative than RAID1 for those who sometimes "SAVE" instead of "SAVE AS"
I recently upgraded from a Linksys NSLU2 (a.k.a. SLUG) which had a built-in feature exactly like this... every day at XX it would copy one drive to another. The SLUG would also e-mail me to confirm that everything went OK.
Is there a way we could add such a feature to this script? Potentially using something like esmtp?
Thanks,
ambanmba
Offline
I tried to create a file like described in step 3, but i get a warning that this file cannot be created.
I can create the file in another directory on my computer or in the root of volume 1 but then copying it to the specified folder is also impossible. The warning tells me i have no permission to the folder. Also with ftp i can't get the file in the right folder.
Offline
knireis - no idea why that is happening. Can you reset the dns (either via the web-interface) or the hard boot via the pin hole at the back and then try to copy the file in?
Cheers
Chumby
Offline
Anbanmba - Great to see it is working well for you. I noticed blbrown had some code (search for "email") in these forums that may be adapted. Perhaps get an email sent to you "saying the job has finished" and then having the log file which has been created sent as an attachment?
blbrown - Do you see this as a possibility for the email script you have created?
Cheers,
Chumby.
Offline
Chumby wrote:
I noticed blbrown had some code (search for "email") in these forums that may be adapted. Perhaps get an email sent to you "saying the job has finished" and then having the log file which has been created sent as an attachment?
Thanks for that... it looks like the post you are referring to is this one:
http://dns323.kood.org/forum/p7404-2007 … html#p7404
ambanmba
Offline
Chumby wrote:
knireis - no idea why that is happening. Can you reset the dns (either via the web-interface) or the hard boot via the pin hole at the back and then try to copy the file in?
Cheers
Chumby
I did the reset both ways, but no luck. I renamed the fun_plug.d folder and installed the funplug .3 again but again the same thing. Also i am not able to delete the renamed (fun_plug.d-old) folder, any idea how to do this? How do i remove the funplug completely and delete all the folders created by the funplug? I can then try again from a fresh start.
Offline
New DNS-323 user here!
I setup fun_plug and installed this script with little or no Linux experience and it works like a charm! Thanks for the hard work guys!
One question, if I have a USD drive to volume_1 as ex. /USB_500 will it try to back this up to the 2nd drive as well? If so how can I add exclusions?
Thanks!
Offline
ambanmba wrote:
Chumby wrote:
I noticed blbrown had some code (search for "email") in these forums that may be adapted. Perhaps get an email sent to you "saying the job has finished" and then having the log file which has been created sent as an attachment?
Thanks for that... it looks like the post you are referring to is this one:
http://dns323.kood.org/forum/p7404-2007 … html#p7404
ambanmba
Yep, my email script can definitely do as you ask--If you grab BackupNetClone (from http://backupnetclone.sourceforge.net/) there are two files that do the actual emailing. Look in complete_email.sh and sendmail.sh (which is an updated version from the one in the forum link you posted).
BackupNetClone is basically a fancy script for the rsync steps outlined in this thread--it sends an email status after the backup is complete. It even reports changed files and disk space remaining on the backup server. Unfortunately, setup is not for the faint of heart because it also uses SSH. The website lays out the basic instructions, but I'm still working on the detailed line-by-line instructions for how to get a whole backup system up and running.
If you email me (details on the website), I can send you the text files I have with all the raw commands that I used to set everything up--it's a bit messy but might help you past some of the installation hurdles.
Another thing to note about the email script I wrote is that it only handles simple SMTP servers--those with no authentication or basic username/pw authentication. So Gmail, Yahoo, and others that require SSL won't allow BackupNetClone to send its status emails. Anyone interested in getting SSL compiled natively for the DNS-323?
Offline
Can someone explain step by step how to create the file named editcron.sh and put it in the fun_plug.d/start directory? I reformatted the drive and installed fonz funplug 0.3. But i can't get acces to this directory (from a windows XP computer).
Offline
Hi Knireis,
It is in the tutorial (towards the top). After you have installed the fun_plug, have you been able to telnet in OK with PUTTY?
Cheers,
Chumby
Offline
Chumby wrote:
Hi Knireis,
It is in the tutorial (towards the top). After you have installed the fun_plug, have you been able to telnet in OK with PUTTY?
Cheers,
Chumby
Yes i can telnet to the NAS, but i copied the file using windows explorer or ftp, but i can't get access to the funplug.d folder or its subfolders. Do i create the file also using putty? How do i do this?
Offline
The fun_plug.d folder and subdirectories were created from the fun_plug script
and fun_plug.tar file, which is run at startup, as the root user. In order to access
these directories and files you need to connect to the DNS-323 as the root user.
You can access the DNS-323, as root, with telnet, and create the files with the vi editor.
Offline
mig wrote:
The fun_plug.d folder and subdirectories were created from the fun_plug script
and fun_plug.tar file, which is run at startup, as the root user. In order to access
these directories and files you need to connect to the DNS-323 as the root user.
You can access the DNS-323, as root, with telnet, and create the files with the vi editor.
Thank you for the information, I'm quite new to this stuff, can you maybe write down the steps to achieve this?
Offline
Chumby did an excellent job of detailing the steps required in the first post of this thread.
What exactly are you having trouble with in the
STEP THREE – Create a Scheduled Backup
section?
Offline
mig wrote:
What exactly are you having trouble with in the
STEP THREE – Create a Scheduled Backup
section?
I can telnet in via putty, but don't know if this is as root and i don't know how to create the editcron.sh file in the specified folder. from there to edit the file the instructions seem to be clear enough
Offline
O.K. I think I see your confusion, The instructions in code box of the section
1) After you have telneted into the dns323 and can see the # prompt, type in the following line of code:
vi /mnt/HD_a2/fun_plug.d/start/editcron.sh
creates the file.
When you issue the vi command with a filename (that does not exist) vi will
create a new blank file, with the name you input.
'vi' is a command line text editor, you should google 'vi editor' to get an overview of the 'vi' editor,
'vi' can be very intimidation for new users.
Also, the telnet server, setup by fun_plug connects as root.
Good luck!
Offline
mig wrote:
O.K. I think I see your confusion, The instructions in code box of the section
1) After you have telneted into the dns323 and can see the # prompt, type in the following line of code:
vi /mnt/HD_a2/fun_plug.d/start/editcron.sh
creates the file.
When you issue the vi command with a filename (that does not exist) vi will
create a new blank file, with the name you input.
'vi' is a command line text editor, you should google 'vi editor' to get an overview of the 'vi' editor,
'vi' can be very intimidation for new users.
Also, the telnet server, setup by fun_plug connects as root.
Good luck!
Thanks
Offline
Someone please help me out here.
On this line
/bin/echo "5 2 * * * /mnt/HD_a2/fun_plug.d/bin/rsync -rlptDv --delete /mnt/HD_a2 /mnt/HD_b2 >/mnt/HD_a2/fun_plug.d/log/rsync.last.log 2>&1" >> $CRONTXT
What do I add if I want to exclude a directory from the sync?
Offline
Nice. However a small correction should be made.
The very first line of your script (as it existed on Jan 11, 2008) is incorrect:
!#/bin/sh
should be changed to
#!/bin/sh
Even with the error the script runs OK, however the following will appear in fun_plug.d\log\fun_plug.log
<snip>
* Running /mnt/HD_a2/fun_plug.d/start/editcron.sh start ...
/mnt/HD_a2/fun_plug.d/start/editcron.sh: !#/bin/sh: No such file or directory
<snip>
Cheers,
Dave.
Offline
marmot74,
telnet in and type "rsync" at the command prompt. You will get the list of all options that rsync accepts. One of the options is:
--exclude=PATTERN exclude files matching PATTERN
Also, a good web page to refer to is the man page:
http://rsync.samba.org/ftp/rsync/rsync.html
--exclude "foo/" would exclude any directory called foo
Cheers,
Dave.
Offline
DaveN wrote:
The very first line of your script (as it existed on Jan 11, 2008) is incorrect:
!#/bin/sh
should be changed to
#!/bin/sh
Nice catch, DaveN. Chumby actually copied this error from a post I made back in 0ct, 2007.
I corrected that post tonight, Chumby can take care of the correction in his writeup in this
thread.
Offline