Welcome to the new location of Alien's Wiki, sharing a single dokuwiki install with the SlackDocs Wiki.

Welcome to Eric Hameleers (Alien BOB)'s Wiki pages.

If you want to support my work, please consider a small donation:

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
linux:slug [2010/03/20 22:17] – My /etc/fstab changes are being overwritten at boot? alienlinux:slug [2010/04/24 18:56] – Remove two slashes that seem to prevent automount. alien
Line 131: Line 131:
 </code> </code>
  
-This will automatically install the dependencies as well:+Please follow carefully the post-installation instructions shown on-screen after installing some of these packages (such as syslog-ng, nfs-utils) or they will not work properly. Sendmail will for instance state: <code bash> 
 +sendmail will run as a daemon now. Alternatively, execute: 
 +echo 'smtp    stream  tcp     nowait  root    /opt/sbin/sendmail -bs' >> /etc/inetd.conf 
 +echo '0-59/15 * * * * root /opt/sbin/sendmail -q  & > /dev/null 2>&1' >> /etc/crontab 
 +</code> 
 + 
 +Installing these base packages will automatically install their dependencies as well:
   * for openssh : openssl, zlib   * for openssh : openssl, zlib
   * for rsnapshot : coreutils, perl, rsync, openssh   * for rsnapshot : coreutils, perl, rsync, openssh
Line 195: Line 201:
 # chmod 0755 /mnt/thevault/.private/.snapshots/ # chmod 0755 /mnt/thevault/.private/.snapshots/
 # chmod 0755 /mnt/thevault/.snapshots/ # chmod 0755 /mnt/thevault/.snapshots/
-</code> In ''/etc/exports'', add the directory ''.private/.snapshots/'' as a read only NFS export: <code>+</code> In ''/opt/etc/exports'', add the directory ''.private/.snapshots/'' as a read only NFS export: <code>
   /mnt/thevault/.private/.snapshots/  127.0.0.1(ro,no_root_squash)   /mnt/thevault/.private/.snapshots/  127.0.0.1(ro,no_root_squash)
 </code> In ''/etc/fstab'', mount ''.private/.snapshots/'' read-only under ''.snapshots/'' <code> </code> In ''/etc/fstab'', mount ''.private/.snapshots/'' read-only under ''.snapshots/'' <code>
-  localhost:/mnt/thevault/.private/.snapshots /mnt/thevault/.snapshots nfs  ro   0 0+  localhost:/mnt/thevault/.private/.snapshots  /mnt/thevault/.snapshots  nfs  ro   0 0
 </code> Now restart the NFS daemon: <code> </code> Now restart the NFS daemon: <code>
 /opt/etc/init.d/S56nfs-utils condrestart /opt/etc/init.d/S56nfs-utils condrestart
Line 212: Line 218:
 </code> As you may notice, these crontab entries schedule the jobs with larger intervals to run a bit before the jobs that trigger more regularly.(//daily// runs 30 minutes before //hourly//; and //weekly// in turn runs 30 minutes before //daily//). This is to prevent for instance the //weekly// rsnapshot job to run before the //daily// job (the same goes for combinations of other intervals). If you would schedule them the other way round, a problem may arise in case the larger interval job would start (re)moving backup directories before the shorter interval job has finished it's work.  </code> As you may notice, these crontab entries schedule the jobs with larger intervals to run a bit before the jobs that trigger more regularly.(//daily// runs 30 minutes before //hourly//; and //weekly// in turn runs 30 minutes before //daily//). This is to prevent for instance the //weekly// rsnapshot job to run before the //daily// job (the same goes for combinations of other intervals). If you would schedule them the other way round, a problem may arise in case the larger interval job would start (re)moving backup directories before the shorter interval job has finished it's work. 
  
-<note>It seems that my changes to ''/etc/fstab'' are being overwritten at boot. However, there is an alternative to mounting through fstab: If the file ''/unslung/rc.local'' exists, it will be executed. So, I created that file (it did not exist) and added <code>+<note>It seems that my changes to ''/etc/fstab'' are being overwritten at boot. However, there is an alternative to mounting through fstab: If the file ''/unslung/rc.local'' exists, it will be executed. So, I copied ''/etc/rc.d/rc.local'' to that file (it did not exist): <code> 
 +cp -a /etc/rc.d/rc.local /unslung/rc.local</code> removed the line <code> 
 +if ( [ -r /unslung/rc.local ] && . /unslung/rc.local ) ; then return 0 ; fi 
 +</code> and then added these lines at the bottom: <code>
 mount -t ext3 -o defaults,usrquota /dev/sdb1 /mnt/thevault mount -t ext3 -o defaults,usrquota /dev/sdb1 /mnt/thevault
 mount -t nfs localhost:/mnt/thevault/.private/.snapshots /mnt/thevault/.snapshots mount -t nfs localhost:/mnt/thevault/.private/.snapshots /mnt/thevault/.snapshots
-return 0 +</code></note>
-</code> The "return 0" will ensure that mount errors will not mess up the remainder of the boot.</note>+
  
 ==== The rsnapshot log file ==== ==== The rsnapshot log file ====
 A backup server using NSLU2, unslung and rsnapshot ()
SlackDocs