Files disappearing from shares, but still exist in pool
Posted: Tue Feb 15, 2011 9:14 pm
So, here's the background.
I built my amahi server and put a clean 2tb drive into it. I used the instructions on the wiki for "adding a second drive" using cfdisk, gparted, etc. Everything worked great. I had 2 640gb hard drives with many files on them, roughly 900gb total. I put them into my desktop machine one at a time and copied all the files over to the /movies share to properly add them to the storage pool.
At some point during the first drive, the transfer died because the root drive filled up. I moved the landing zone onto the 2tb drive to prevent the transfer from dieing again. After that, the first drive went fine. All the files moved properly, I tested a handful at random, great. I noticed that even though I moved the landing zone to the 2tb drive, it was still slow. I used iotop to check, and the 2tb drive was still maxing out since the landing zone was on it and the files were being moved to it.
I then took that 640gb drive (the one I had just copied files off of) and added it to the storage pool, again according to the wiki instructions. Right after that, I moved the landing zone onto that drive so that I could spread the io across the two drives. Once that was complete, I started copying files from the second drive over to the storage pool.
After copying the rest over, I confirmed everything was there. Then I pulled the 2nd 640gb drive from my desktop and intended to add it to the storage pool as well. Once I got it hooked up to the amahi machine, I did one last check on the /movies share to make sure all my files were still there before wiping the drive. It turns out, half of my files from the /movies share are missing. Looking at the amahi setup dashboard, it's still showing all of the space on the 2tb drive used, so the files are still there, but the links in the share seem to be broken. I tried a greyhole --fsck but that didn't fix it. I've restarted the machine a couple of times, still to no avail.
Someone on IRC at #amahi helped me a little bit and I was able to discover that all the files are still in the pool... stored in /var/hda/files/drives/drive1/movies, but only half of them (the half in the share) are in /var/hda/files/drives/drive1/gh/movies.
If you can help me recreate the links to the files that are broken, that would be awesome.
Thanks in advance!
---------------
Here is the required info:
1.
Fedora: 2.6.31.5-127.fc12.x86_64
Samba: 3.4.2-47.fc12.x86_64
Greyhole: hda-greyhole-0.7.5-1.x86_64
2.
http://fpaste.org/DPSP/
http://fpaste.org/7KwS/
3.
/dev/mapper/VolGroup-lv_root on / type ext4 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
tmpfs on /dev/shm type tmpfs (rw)
/dev/sdc1 on /boot type ext4 (rw)
/dev/sda1 on /var/hda/files/drives/drive1 type ext4 (rw)
/dev/sdb1 on /var/hda/files/drives/drive2 type ext4 (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
gvfs-fuse-daemon on /home/Workdawg/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=Workdawg)
Disk /dev/sda: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x0001190b
Device Boot Start End Blocks Id System
/dev/sda1 1 243202 1953513472 83 Linux
Disk /dev/sdb: 640.1 GB, 640135028736 bytes
255 heads, 63 sectors/track, 77825 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000
Device Boot Start End Blocks Id System
/dev/sdb1 1 77825 625129281 83 Linux
Disk /dev/sdc: 20.4 GB, 20416757760 bytes
255 heads, 63 sectors/track, 2482 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x14844613
Device Boot Start End Blocks Id System
/dev/sdc1 * 1 26 204800 83 Linux
Partition 1 does not end on cylinder boundary.
/dev/sdc2 26 2482 19731833+ 8e Linux LVM
Disk /dev/dm-0: 16.0 GB, 15976103936 bytes
255 heads, 63 sectors/track, 1942 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 4227 MB, 4227858432 bytes
255 heads, 63 sectors/track, 514 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VolGroup-lv_root
15G 3.6G 11G 26% /
tmpfs 1006M 560K 1005M 1% /dev/shm
/dev/sdc1 194M 23M 162M 13% /boot
/dev/sda1 1.8T 888G 853G 52% /var/hda/files/drives/drive1
/dev/sdb1 587G 37G 521G 7% /var/hda/files/drives/drive2
Greyhole Statistics
===================
Storage Pool
Total - Used = Free + Attic = Possible
/var/hda/files/drives/drive1/gh: 1834G - 888G = 853G + 8G = 860G
/var/hda/files/drives/drive2/gh: 587G - 37G = 520G + 0G = 520G
4.
1 | /var/hda/files/drivers/drive1 | 10 | 2011-02-12 12:42:49 | 2011-02-12 12:42:49
2 | /var/hda/files/drivers/drive2 | 10 | 2011-02-14 00:59:16 | 2011-02-14 00:59:16
5.
http://fpaste.org/oCnX/
6.
greyhole queue is 0 for all functions on all shares.
7. One of the missing files
http://fpaste.org/bwZg/
Another, that seems like it was there at first, then went missing: http://fpaste.org/KKBb/
I built my amahi server and put a clean 2tb drive into it. I used the instructions on the wiki for "adding a second drive" using cfdisk, gparted, etc. Everything worked great. I had 2 640gb hard drives with many files on them, roughly 900gb total. I put them into my desktop machine one at a time and copied all the files over to the /movies share to properly add them to the storage pool.
At some point during the first drive, the transfer died because the root drive filled up. I moved the landing zone onto the 2tb drive to prevent the transfer from dieing again. After that, the first drive went fine. All the files moved properly, I tested a handful at random, great. I noticed that even though I moved the landing zone to the 2tb drive, it was still slow. I used iotop to check, and the 2tb drive was still maxing out since the landing zone was on it and the files were being moved to it.
I then took that 640gb drive (the one I had just copied files off of) and added it to the storage pool, again according to the wiki instructions. Right after that, I moved the landing zone onto that drive so that I could spread the io across the two drives. Once that was complete, I started copying files from the second drive over to the storage pool.
After copying the rest over, I confirmed everything was there. Then I pulled the 2nd 640gb drive from my desktop and intended to add it to the storage pool as well. Once I got it hooked up to the amahi machine, I did one last check on the /movies share to make sure all my files were still there before wiping the drive. It turns out, half of my files from the /movies share are missing. Looking at the amahi setup dashboard, it's still showing all of the space on the 2tb drive used, so the files are still there, but the links in the share seem to be broken. I tried a greyhole --fsck but that didn't fix it. I've restarted the machine a couple of times, still to no avail.
Someone on IRC at #amahi helped me a little bit and I was able to discover that all the files are still in the pool... stored in /var/hda/files/drives/drive1/movies, but only half of them (the half in the share) are in /var/hda/files/drives/drive1/gh/movies.
If you can help me recreate the links to the files that are broken, that would be awesome.
Thanks in advance!
---------------
Here is the required info:
1.
Fedora: 2.6.31.5-127.fc12.x86_64
Samba: 3.4.2-47.fc12.x86_64
Greyhole: hda-greyhole-0.7.5-1.x86_64
2.
http://fpaste.org/DPSP/
http://fpaste.org/7KwS/
3.
/dev/mapper/VolGroup-lv_root on / type ext4 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
tmpfs on /dev/shm type tmpfs (rw)
/dev/sdc1 on /boot type ext4 (rw)
/dev/sda1 on /var/hda/files/drives/drive1 type ext4 (rw)
/dev/sdb1 on /var/hda/files/drives/drive2 type ext4 (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
gvfs-fuse-daemon on /home/Workdawg/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=Workdawg)
Disk /dev/sda: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x0001190b
Device Boot Start End Blocks Id System
/dev/sda1 1 243202 1953513472 83 Linux
Disk /dev/sdb: 640.1 GB, 640135028736 bytes
255 heads, 63 sectors/track, 77825 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000
Device Boot Start End Blocks Id System
/dev/sdb1 1 77825 625129281 83 Linux
Disk /dev/sdc: 20.4 GB, 20416757760 bytes
255 heads, 63 sectors/track, 2482 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x14844613
Device Boot Start End Blocks Id System
/dev/sdc1 * 1 26 204800 83 Linux
Partition 1 does not end on cylinder boundary.
/dev/sdc2 26 2482 19731833+ 8e Linux LVM
Disk /dev/dm-0: 16.0 GB, 15976103936 bytes
255 heads, 63 sectors/track, 1942 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 4227 MB, 4227858432 bytes
255 heads, 63 sectors/track, 514 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VolGroup-lv_root
15G 3.6G 11G 26% /
tmpfs 1006M 560K 1005M 1% /dev/shm
/dev/sdc1 194M 23M 162M 13% /boot
/dev/sda1 1.8T 888G 853G 52% /var/hda/files/drives/drive1
/dev/sdb1 587G 37G 521G 7% /var/hda/files/drives/drive2
Greyhole Statistics
===================
Storage Pool
Total - Used = Free + Attic = Possible
/var/hda/files/drives/drive1/gh: 1834G - 888G = 853G + 8G = 860G
/var/hda/files/drives/drive2/gh: 587G - 37G = 520G + 0G = 520G
4.
1 | /var/hda/files/drivers/drive1 | 10 | 2011-02-12 12:42:49 | 2011-02-12 12:42:49
2 | /var/hda/files/drivers/drive2 | 10 | 2011-02-14 00:59:16 | 2011-02-14 00:59:16
5.
http://fpaste.org/oCnX/
6.
greyhole queue is 0 for all functions on all shares.
7. One of the missing files
http://fpaste.org/bwZg/
Another, that seems like it was there at first, then went missing: http://fpaste.org/KKBb/