Re: netatalk, NFS, OS X and backup

From: Shane Ambler (Shane_at_007Marketing.com)
Date: 01/10/05

  • Next message: Jez Han***: "Re: Blacklisting IPs"
    Date: Tue, 11 Jan 2005 06:04:21 +1030
    To: Martin Hepworth <maxsec@gmail.com>, FreeBSD Mailing Lists <freebsd-questions@freebsd.org>
    
    

    Personally I use a combination of applescript and cli.

    With applescript you create a script that mounts the remote afp volume.

    Eg in script editor
    On run
       try
         mount volume "afp://server/sharepoint" as user name "name" with
    password "crypt"
       on error
        --
       end try
    End run

    Personally I put the mount command inside the try block to prevent error
    dialogs coming up - that is why the -- (a comment line) is after on error -
    it tricks the script into doing nothing on error.

    As you might guess this is plain text - for security when you save it you
    can save as application and tick the run only box - this prevents the file
    being opened in the script editor and read - you can open and run it but not
    see the source.

    This will mount the specific share point - it shows up in
    /volumes/sharepoint - which can then be copied to/from

    I then use the cli to compress/copy files - personally I use stuffit deluxe
    for compression as the deluxe version includes the cli tools and handles
    resource forks / meta data etc.

    #! /bin/sh
    /usr/local/bin/stuff -f sitx -n /pathto/backupfile /pathto/filestobackup

    cp /pathto/backupfile /volumes/sharepoint/backupfile

    Of course you put the date/numbers into the filename as you prefer.

    One gotcha to look out for is if the sharepoint doesn't mount for whatever
    reason the cp step will create a folder in /volumes and will copy locally
    instead of to the server. There is also the option of using scp to get the
    files to the server.

    There is a cli - mount_afp - when I tried it some time ago I had some
    problem(can't remember what now) so I used the applescript instead.

    You then setup cron to run the applescript and the shell script when you
    want.

    With the applescript it is a gui app so in cron you need
    /usr/bin/open /pathto/applescript.app
    Remember the .app is not shown in the finder but is needed for the cli,
    easy to miss.

    On 11/1/05 2:15 AM, "Martin Hepworth" <maxsec@gmail.com> wrote:

    > have you looked at amanda? Uses it's daemons to transfer the data, and
    > you can select where to comress (on client or server).
    >
    > works well when used with hfstar on MacOS X ...
    >
    > restores are normally done by the admin and currently its a cli...no
    > plans AFAIK to make this a gui.
    >
    > ---
    > Martin
    >
    >
    > On Fri, 7 Jan 2005 11:29:59 -0500, Alan Curtis <acurtis@ieee.org> wrote:
    >> I need some advice about integrating my FreeBSD server with some Macs
    >> running OS X.
    >>
    >> I have a server running FreeBSD 5.3 with NFS and netatalk enabled, a
    >> Powerbook G4 running OS X 10.3.7 and they are connected through a
    >> wireless network. I used the Powerbook to administer the server using
    >> ssh, which works well. I would also like to use the server to backup
    >> files (for multiple users) from the Powerbook. I have played around
    >> with both NFS and netatalk (afpd) and both seem to be working, in that
    >> I can manually mount the shares on the Powerbook. I have got the NFS
    >> share to automount on the Powerbook but not the afp share. I can copy
    >> files to and from both the nfs and afp mounted shares, including
    >> resource forks. I have played with various backup utilities including
    >> rsync, psync and rdiff-backup with varying degrees of success.
    >>
    >> Some observations/questions
    >>
    >> 1. netatalk afp seems consistently and significantly faster than nfs.
    >> Is this to be expected or might I have a problem with nfs? If so how do
    >> I diagnose and fix it?
    >>
    >> 2. I would prefer to use nfs, because I can automount it on the
    >> Powerbook and run a cron (actually anacron) script to backup the
    >> multiple users. I haven't yet worked out how (or if) I can do this with
    >> afp (this is really a Mac question I know).
    >>
    >> 3. I would like to use a backup scheme which is automatic, invisible to
    >> the user, yet configured in a way that the archive can be navigated,
    >> and files appear in folders on the Mac finder in a consistent way (with
    >> resource forks set up correctly).
    >>
    >> All of this seems almost possible, yet I don't seem to have got it just
    >> right yet. Has anyone one any insight they can spread or experiences
    >> they can share of a similar set up?
    >>
    >> Alan
    >>
    >> _______________________________________________
    >> freebsd-questions@freebsd.org mailing list
    >> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
    >> To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"
    >>
    > _______________________________________________
    > freebsd-questions@freebsd.org mailing list
    > http://lists.freebsd.org/mailman/listinfo/freebsd-questions
    > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"
    >

    -- 
    Shane Ambler
    Sales Department
    007Marketing.com
    Shane@007Marketing.com
    _______________________________________________
    freebsd-questions@freebsd.org mailing list
    http://lists.freebsd.org/mailman/listinfo/freebsd-questions
    To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"
    

  • Next message: Jez Han***: "Re: Blacklisting IPs"