[PLUG] <Solved!> No space left on device

John Jason Jordan johnxj at gmx.com
Thu Oct 26 04:48:15 UTC 2017


On Wed, 25 Oct 2017 15:42:37 -0700
Dale Snell <ddsnell at frontier.com> dijo:

>Ah, okay.  You'll have to unplug the Synology in order to find
>those movies.  They're in whatever filesystem the Synology mounts
>in.  Say you have a directory "/mnt/storage/".  If you do an
>"ls /mnt/storage", nothing will show up.  When you mount your new
>filesystem (say, the Synology) on /mnt/storage, doing the
>"ls /mnt/storage" will report whatever is in the new filesystem.
>If you create files in /mnt/storage/ _before_ mounting the
>Synology, and _then_ mount the Synology, you won't see those
>files, just the Synology's.

Free space: 57.9 GB of 82.4 GB (29% used)

Hallelujah!!

Now that things are back to normal I want to work on making sure that
this never happens again.

>One thing I learned to do in a previous life, when I helped
>administer a Sun III, was to mark unmounted filesystems.  Use
>mkdir as usual to create the mountpoint directory (mkdir blorfl),
>then immediately do a "touch blorfl/not_mounted".  When you do
>a directory listing of blorfl, it should show "not_mounted" only.
>If there are other files there, you've got a problem.

The 'not mounted' file is a good idea. There is a
folder /media/jjj/Synology and that is where the Synology is mounted.
From fstab:

	192.168.1.115:/volume1/Synology /media/jjj/Synology nfs
		auto,user 0 0
	#it took me a long time to get that fstab line right

And here is the rsync command:

	 rsync -rptog --progress --stats --delete
		 --exclude-from=/media/jjj/Movies/rsync_exclusions /media/jjj/Movies/ /media/jjj/Synology

It seems to me that maybe a simple way to make sure this never happens
again is to modify the rsync command so that if the Synology is not
mounted the command aborts. Even better, if it aborts it should send me
a message so I know that things are amiss. Wait ... a pop-up with
gxmessage would be better. OK, this sounds like I need a script instead
of just a raw command. 

	if <synology not mounted> then gxmessage "Movies backup failed"
	else rsync -rptog ... etc.

I can do really, really simple bash scripts but I don't know how to do
<synology not mounted>. Also unsure about bash syntax for if-then-else.
Oh, and gxmessage is installed, as I use it to pop up a list of Unicode
values for characters in IPA.

Thanks a major bunch to you and everyone else who helped. Next time we
meet I owe you a beer! Several beers!



More information about the PLUG mailing list