1 (edited by gedakc 2016-05-04 22:04:25)

Topic: [closed] Growing HFS filesystems

Hi People!

My request is about adding Clonezilla to the Gparted testing versions. And the reason is that I've heard succesfull stories about growing partitions in filesystems that Gparted don't know how to have an approach currently.

The idea is the next, for example, in order to grow a hfs filesystem:

1- Create temporarily a compressed image of the hfs filesystem in the non-used space of a disk or by mount temporarily a filesystem in which you can write
2.-Delete the hfs filesystem
3.- Create a new one bigger
4.- Extract the hfs compressed image to the new big hfs filesystem
5.- Delete the hfs compressed image from the non-used space of the disk or from the filesystem you wrote the hfs compressed image
6.- Umount the filesystem if you used the mount option to save the hfs compressed image
7.- Test the new filesystem

What do you think about this idea? I think with luck we can get testers providing opinions from non-production systems. And moreover, it doesn't seem to need a lot of added source code - we can call clonezilla application from inside Gparted, for instance.

I hope your opinion!

Regards

2

Re: [closed] Growing HFS filesystems

Thank you videoclock for posting this request in the forum.

Is this request to be able to (A) create and restore backup images, or is the request for (B) growing hfs (and perhaps other unsupported) file systems?

A)  If this request is regarding being able to create backup images from GParted then similar requests have been raised as follows:
Create and restore file system images
Bug #364324 - File system images support

B)  If this request is regarding growing hfs file systems (or other currently unsupported file systems), then more investigation is required.

Have you tried using the above steps you posted?

I have not tried these myself, but I think that the restored compressed hfs image would have the same size file system even if the partition was larger.  As far as I know there are no free software tools for growing hfs file systems.

If you could test, document, and post your results it would help to determine if the approach is feasible.

3

Re: [closed] Growing HFS filesystems

Hi Gedak,

Thanks for interesting in that.

Actually I refer to the B. I haven't tried the steps I posted. However, I'm interested in that and adding functionality to the currently unsupported file systems.

To be honest, I'm not very experienced with filesystems and the implementations details. However, I think a lot of open source code and open source utilities can be reused to get things easier.

If I do tests like the one I posted, I'll share it with the users in order to expand the knowledge and to add possible functionality.

Regards

4

Re: [closed] Growing HFS filesystems

I am interested to learn what you discover when you try out the steps you listed.   smile

5

Re: [closed] Growing HFS filesystems

Hi people!

I've tried what I told, so I'm gonna explain the results of my experiments:

In Windows XP, I've installed VirtualBox and Ubuntu 10 virtual machine on it.

Then in the Ubuntu virtual machine I've installed Gparted application 0.8.0-5 and all packages that I can read in filesystem support menu of the app.

Then my virtual hard drive stays as following:

/dev/sda1 Ubuntu ext4 6GB boot
/dev/sda2 extended 2.09 GB
                 /dev/sda5 linux-swap 250 MB
                 unused space 250 MB
                 /dev/sda6 btrfs 250 MB
                 unused space 250 MB
                 /dev/sda7 HFS 250 MB
                 unused space 250 MB
                 /dev/sda8 HFS+ 250 MB
                 unused space 250 MB
                 /dev/sda9 reiser4 250 MB
                 unused space 250 MB

I apply in Gparted, all operations done succesfully, exit

I can mount now all filesystems except reiser4 (I don't know the required packages)

Then I copy some files to the three fillesystems

Next I boot from Clonezilla (still from virtualBox) and create a compressed image of each filesystem.

Then I boot from Gparted Live CD (still from virtualBox) and delete the four partitions and create new of them, staying my virtual hard drive as following:


/dev/sda1 Ubuntu ext4 6GB boot
/dev/sda2 extended 2.09 GB
                 /dev/sda5 linux-swap 400  MB
                 /dev/sda6 btrfs 500 MB
                 /dev/sda7 HFS 500 MB
                 /dev/sda8 HFS+ 500 MB
                 /dev/sda9 reiser4 500 MB

Then I boot from Clonezilla again and restore the four compressed images in the correct partitions. The only partition which gives me error is the reiser4 partition.

Then I boot Ubuntu and run gparted to know if something went wrong. I realize that Gparted recognizes the reiser4 partition as 'unknown', possibly due to the error restoring the image in Clonezilla.
Next, in bash, I try to fsck the four partitions before mounting them. I've run a lot of commands in this step and you can read all in the next bash history:

casa@casa-VirtualBox:~$ sudo bash 
[sudo] password for casa: 
root@casa-VirtualBox:~# cd /usr/src 
root@casa-VirtualBox:/usr/src# mkdir hfsplus_support 
root@casa-VirtualBox:/usr/src# wget http://gentoo.osuosl.org/distfiles/diskdev_cmds-332.14.tar.gz 
--2011-03-31 10:10:32--  http://gentoo.osuosl.org/distfiles/diskdev_cmds-332.14.tar.gz 
Resolviendo gentoo.osuosl.org... 64.50.236.52, 64.50.233.100 
Conectando a gentoo.osuosl.org|64.50.236.52|:80... conectado. 
Petición HTTP enviada, esperando respuesta... 200 OK 
Longitud: 714035 (697K) [application/x-gzip] 
Guardando en: «diskdev_cmds-332.14.tar.gz» 

100%[====================================================================================>] 714.035     69,4K/s   en 11s     

2011-03-31 10:10:44 (65,6 KB/s) - «diskdev_cmds-332.14.tar.gz» guardado [714035/714035] 

root@casa-VirtualBox:/usr/src# wget http://www.ecl.udel.edu/~mcgee/diskdev_cmds/diskdev_cmds-332.14.patch.bz2 
--2011-03-31 10:12:17--  http://www.ecl.udel.edu/~mcgee/diskdev_cmds/diskdev_cmds-332.14.patch.bz2 
Resolviendo www.ecl.udel.edu... 128.4.40.36 
Conectando a www.ecl.udel.edu|128.4.40.36|:80... conectado. 
Petición HTTP enviada, esperando respuesta... 404 Not Found 
2011-03-31 10:12:19 ERROR 404: Not Found. 

root@casa-VirtualBox:/usr/src# wget http://www.mythic-beasts.com/resources/appletv/mb_boot_tv/diskdev_cmds-332.14.patch.bz2 
--2011-03-31 10:18:00--  http://www.mythic-beasts.com/resources/appletv/mb_boot_tv/diskdev_cmds-332.14.patch.bz2 
Resolviendo www.mythic-beasts.com... 93.93.130.49 
Conectando a www.mythic-beasts.com|93.93.130.49|:80... conectado. 
Petición HTTP enviada, esperando respuesta... 200 OK 
Longitud: 20960 (20K) [text/plain] 
Guardando en: «diskdev_cmds-332.14.patch.bz2» 

100%[====================================================================================>] 20.960      51,5K/s   en 0,4s    

2011-03-31 10:18:01 (51,5 KB/s) - «diskdev_cmds-332.14.patch.bz2» guardado [20960/20960] 

root@casa-VirtualBox:/usr/src# tar zxf diskdev_cmds-332.14.tar.gz 
root@casa-VirtualBox:/usr/src# bunzip2 -c diskdev_cmds-332.14.patch.bz2 | patch -p0 
El programa «patch» no está instalado actualmente.  Puede instalarlo escribiendo: 
apt-get install patch 
root@casa-VirtualBox:/usr/src# apt-get install patch 
Leyendo lista de paquetes... Hecho 
Creando árbol de dependencias       
Leyendo la información de estado... Hecho 
Paquetes sugeridos: 
  diffutils-doc 
Se instalarán los siguientes paquetes NUEVOS: 
  patch 
0 actualizados, 1 se instalarán, 0 para eliminar y 293 no actualizados. 
Necesito descargar 123kB de archivos. 
Se utilizarán 254kB de espacio de disco adicional después de esta operación. 
Des:1 http://es.archive.ubuntu.com/ubuntu/ maverick/main patch i386 2.6-2ubuntu1 [123kB] 
Descargados 123kB en 1s (72,7kB/s) 
Seleccionando el paquete patch previamente no seleccionado. 
(Leyendo la base de datos ...  00% 
146949 ficheros y directorios instalados actualmente.) 
Desempaquetando patch (de .../patch_2.6-2ubuntu1_i386.deb) ... 
Procesando disparadores para man-db ... 
Configurando patch (2.6-2ubuntu1) ... 
root@casa-VirtualBox:/usr/src# bunzip2 -c diskdev_cmds-332.14.patch.bz2 | patch -p0 
patching file diskdev_cmds-332.14/Makefile.lnx 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/Makefile.lnx 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/cache.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/BTree.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/BTreeTreeOps.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/BlockCache.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/Makefile.lnx 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/SBTree.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/SControl.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/SDevice.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/SKeyCompare.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/SRepair.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/SRuntime.h 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/SUtils.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/SVerify2.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/Scavenger.h 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/hfs_endian.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/dfalib/hfs_endian.h 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/fsck_hfs.c 
patching file diskdev_cmds-332.14/fsck_hfs.tproj/utilities.c 
patching file diskdev_cmds-332.14/include/bitstring.h 
patching file diskdev_cmds-332.14/include/hfs/hfs_format.h 
patching file diskdev_cmds-332.14/include/hfs/hfs_mount.h 
patching file diskdev_cmds-332.14/include/missing.h 
patching file diskdev_cmds-332.14/include/sys/appleapiopts.h 
patching file diskdev_cmds-332.14/newfs_hfs.tproj/Makefile.lnx 
patching file diskdev_cmds-332.14/newfs_hfs.tproj/hfs_endian.c 
patching file diskdev_cmds-332.14/newfs_hfs.tproj/hfs_endian.h 
patching file diskdev_cmds-332.14/newfs_hfs.tproj/makehfs.c 
patching file diskdev_cmds-332.14/newfs_hfs.tproj/newfs_hfs.c 
patching file diskdev_cmds-332.14/newfs_hfs.tproj/newfs_hfs.h 
root@casa-VirtualBox:/usr/src# cd diskdev_cmds-332.14/ 
root@casa-VirtualBox:/usr/src/diskdev_cmds-332.14# make -f Makefile.lnx 
for d in newfs_hfs.tproj fsck_hfs.tproj; do make -C $d -f Makefile.lnx all; done 
make[1]: se ingresa al directorio `/usr/src/diskdev_cmds-332.14/newfs_hfs.tproj' 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o hfs_endian.o hfs_endian.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o makehfs.o makehfs.c 
makehfs.c:54: fatal error: openssl/sha.h: No existe el archivo o directorio 
compilation terminated. 
make[1]: *** [makehfs.o] Error 1 
make[1]: se sale del directorio `/usr/src/diskdev_cmds-332.14/newfs_hfs.tproj' 
make[1]: se ingresa al directorio `/usr/src/diskdev_cmds-332.14/fsck_hfs.tproj' 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o fsck_hfs.o fsck_hfs.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o strings.o strings.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o utilities.o utilities.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o cache.o cache.c 
make -C dfalib -f Makefile.lnx libdfa.a 
make[2]: se ingresa al directorio `/usr/src/diskdev_cmds-332.14/fsck_hfs.tproj/dfalib' 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o hfs_endian.o hfs_endian.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o BlockCache.o BlockCache.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o BTree.o BTree.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o BTreeAllocate.o BTreeAllocate.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o BTreeMiscOps.o BTreeMiscOps.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o BTreeNodeOps.o BTreeNodeOps.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o BTreeScanner.o BTreeScanner.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o BTreeTreeOps.o BTreeTreeOps.c 
BTreeTreeOps.c: In function ‘InsertLevel’: 
BTreeTreeOps.c:436: warning: pointer targets in passing argument 1 of ‘DebugStr’ differ in signedness 
SRuntime.h:141: note: expected ‘ConstStr255Param’ but argument is of type ‘char *’ 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o CatalogCheck.o CatalogCheck.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o HardLinkCheck.o HardLinkCheck.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SBTree.o SBTree.c 
SBTree.c: In function ‘SearchBTreeRecord’: 
SBTree.c:96: warning: pointer targets in passing argument 1 of ‘DebugStr’ differ in signedness 
SRuntime.h:141: note: expected ‘ConstStr255Param’ but argument is of type ‘char *’ 
SBTree.c: In function ‘GetBTreeRecord’: 
SBTree.c:193: warning: pointer targets in passing argument 1 of ‘DebugStr’ differ in signedness 
SRuntime.h:141: note: expected ‘ConstStr255Param’ but argument is of type ‘char *’ 
SBTree.c: In function ‘InsertBTreeRecord’: 
SBTree.c:225: warning: pointer targets in passing argument 1 of ‘DebugStr’ differ in signedness 
SRuntime.h:141: note: expected ‘ConstStr255Param’ but argument is of type ‘char *’ 
SBTree.c: In function ‘ReplaceBTreeRecord’: 
SBTree.c:287: warning: pointer targets in passing argument 1 of ‘DebugStr’ differ in signedness 
SRuntime.h:141: note: expected ‘ConstStr255Param’ but argument is of type ‘char *’ 
SBTree.c: In function ‘SetEndOfForkProc’: 
SBTree.c:326: warning: pointer targets in passing argument 1 of ‘DebugStr’ differ in signedness 
SRuntime.h:141: note: expected ‘ConstStr255Param’ but argument is of type ‘char *’ 
SBTree.c: In function ‘CheckBTreeKey’: 
SBTree.c:424: warning: pointer targets in passing argument 1 of ‘DebugStr’ differ in signedness 
SRuntime.h:141: note: expected ‘ConstStr255Param’ but argument is of type ‘char *’ 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SControl.o SControl.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SVerify1.o SVerify1.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SVerify2.o SVerify2.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SRepair.o SRepair.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SRebuildCatalogBTree.o SRebuildCatalogBTree.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SUtils.o SUtils.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SKeyCompare.o SKeyCompare.c 
SKeyCompare.c: In function ‘CompareAttributeKeys’: 
SKeyCompare.c:475: warning: initialization discards qualifiers from pointer target type 
SKeyCompare.c:476: warning: initialization discards qualifiers from pointer target type 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SDevice.o SDevice.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SExtents.o SExtents.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SAllocate.o SAllocate.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SCatalog.o SCatalog.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o SStubs.o SStubs.c 
gcc -g3 -Wall -I/usr/src/diskdev_cmds-332.14/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -D LINUX=1 -D BSD=1   -c -o VolumeBitmapCheck.o VolumeBitmapCheck.c 
ar rc libdfa.a hfs_endian.o BlockCache.o BTree.o BTreeAllocate.o BTreeMiscOps.o BTreeNodeOps.o BTreeScanner.o BTreeTreeOps.o CatalogCheck.o HardLinkCheck.o SBTree.o SControl.o SVerify1.o SVerify2.o SRepair.o SRebuildCatalogBTree.o SUtils.o SKeyCompare.o SDevice.o SExtents.o SAllocate.o SCatalog.o SStubs.o VolumeBitmapCheck.o 
make[2]: se sale del directorio `/usr/src/diskdev_cmds-332.14/fsck_hfs.tproj/dfalib' 
gcc   fsck_hfs.o strings.o utilities.o cache.o dfalib/libdfa.a   -o fsck_hfs 
make[1]: se sale del directorio `/usr/src/diskdev_cmds-332.14/fsck_hfs.tproj' 
root@casa-VirtualBox:/usr/src/diskdev_cmds-332.14# cp fsck_hfs.tproj/fsck_hfs /sbin/fsck.hfsplus 
root@casa-VirtualBox:/usr/src/diskdev_cmds-332.14# cd /sbin 
root@casa-VirtualBox:/sbin# ln -s mkfs.hfsplus mkfs.hfs 
ln: creando el enlace simbólico «mkfs.hfs»: El archivo ya existe 
root@casa-VirtualBox:/sbin# ln -s fsck.hfsplus fsck.hfs 
ln: creando el enlace simbólico «fsck.hfs»: El archivo ya existe 
root@casa-VirtualBox:/sbin# sudo fsck.hfsplus -r /dev/sda7 
** /dev/sda7 
** Checking HFS volume. 
   Invalid B-tree node size 
(4, 0) 
** Volume check failed. 
root@casa-VirtualBox:/sbin# fsck_hfs -p -d /dev/sda7 
fsck_hfs: orden no encontrada 
root@casa-VirtualBox:/sbin# find / -name fsck_hfs 
/usr/src/diskdev_cmds-332.14/fsck_hfs.tproj/fsck_hfs 
root@casa-VirtualBox:/sbin# /usr/src/diskdev_cmds-332.14/fsck_hfs.tproj/fsck_hfs -p /dev/sda7 
root@casa-VirtualBox:/sbin# mount /dev/sda7 /mnt/sda7 
root@casa-VirtualBox:/sbin# cd /mnt/sda7 
root@casa-VirtualBox:/mnt/sda7# 
root@casa-VirtualBox:/mnt/sda7# ls 
carpetaprueba  carpetaprueba2  INFORMATICA.PDF 
root@casa-VirtualBox:/mnt/sda7# cd carpetaprueba 
root@casa-VirtualBox:/mnt/sda7/carpetaprueba# ls 
IE7-WindowsXP-x86-esn.exe 
root@casa-VirtualBox:/mnt/sda7/carpetaprueba# cd .. 
root@casa-VirtualBox:/mnt/sda7# cd carpetaprueba2 
root@casa-VirtualBox:/mnt/sda7/carpetaprueba2# ls 
IE7-WindowsXP-x86-esn.exe 
root@casa-VirtualBox:/mnt/sda7/carpetaprueba2# cd .. 
root@casa-VirtualBox:/mnt/sda7# sudo fsck.hfsplus -r /dev/sda8 
** /dev/sda8 
** Checking HFS Plus volume. 
   Invalid B-tree node size 
(3, 0) 
** Volume check failed. 
root@casa-VirtualBox:/mnt/sda7# fsck_hfs -p -d /dev/sda8 
fsck_hfs: orden no encontrada 
root@casa-VirtualBox:/mnt/sda7# /usr/src/diskdev_cmds-332.14/fsck_hfs.tproj/fsck_hfs -p /dev/sda8 
root@casa-VirtualBox:/mnt/sda7# mount /dev/sda8 /mnt/sda8 
root@casa-VirtualBox:/mnt/sda7# cd /mnt/sda8 
root@casa-VirtualBox:/mnt/sda8# ls 
carpetaprueba  INFORMATICA.PDF 
root@casa-VirtualBox:/mnt/sda8# cd carpetaprueba/ 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# ls 
IE7-WindowsXP-x86-esn.exe 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# btrfsck /dev/sda6 
found 28672 bytes used err is 0 
total csum bytes: 0 
total tree bytes: 28672 
total fs tree bytes: 8192 
btree space waste bytes: 22967 
file data blocks allocated: 0 
 referenced 0 
Btrfs Btrfs v0.19 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# mount /dev/sda8 /mnt/sda8 
mount: /dev/sda8 ya está montado o /mnt/sda8 está ocupado 
mount: según mtab, /dev/sda8 ya está montado en /mnt/sda8 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# cd /mnt/sda8 
root@casa-VirtualBox:/mnt/sda8# ls 
carpetaprueba  INFORMATICA.PDF 
root@casa-VirtualBox:/mnt/sda8# cd carpetaprueba/ 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# ls 
IE7-WindowsXP-x86-esn.exe 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# umount /dev/sda8 
umount: /mnt/sda8: device is busy. 
        (In some cases useful info about processes that use 
         the device is found by lsof(8) or fuser(1)) 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# fsck.hfsplus -r /dev/sda8 
** /dev/sda8 
** Checking HFS Plus volume. 
   Invalid B-tree node size 
(3, 0) 
** Volume check failed. 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# fsck.hfsplus -r /dev/sda7 
** /dev/sda7 
** Checking HFS volume. 
   Invalid B-tree node size 
(4, 0) 
** Volume check failed. 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# fsck.hfsplus -p -d /dev/sda7 
/dev/sda7: starting 
** Checking HFS volume. 
   Invalid B-tree node size 
(4, 0) 
** Volume check failed. 
volume check failed with error 7 
    volume type is HFS 
    primary MDB is at block 2 0x02 
    alternate MDB is at block 890878 0xd97fe 
    primary VHB is at block 0 0x00 
    alternate VHB is at block 0 0x00 
    sector size = 512 0x200 
    VolumeObject flags = 0x19 
    total sectors for volume = 890880 0xd9800 
    total sectors for embedded volume = 0 0x00 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# fsck.hfsplus -p -d /dev/sda8 
/dev/sda8: starting 
** Checking HFS Plus volume. 
   Invalid B-tree node size 
(3, 0) 
** Volume check failed. 
volume check failed with error 7 
    volume type is pure HFS+ 
    primary MDB is at block 0 0x00 
    alternate MDB is at block 0 0x00 
    primary VHB is at block 2 0x02 
    alternate VHB is at block 825342 0xc97fe 
    sector size = 512 0x200 
    VolumeObject flags = 0x07 
    total sectors for volume = 825344 0xc9800 
    total sectors for embedded volume = 0 0x00 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# fsck.hfsplus -y -d /dev/sda8 
** /dev/sda8 
** Checking HFS Plus volume. 
   Invalid B-tree node size 
(3, 0) 
** Volume check failed. 
volume check failed with error 7 
    volume type is pure HFS+ 
    primary MDB is at block 0 0x00 
    alternate MDB is at block 0 0x00 
    primary VHB is at block 2 0x02 
    alternate VHB is at block 825342 0xc97fe 
    sector size = 512 0x200 
    VolumeObject flags = 0x07 
    total sectors for volume = 825344 0xc9800 
    total sectors for embedded volume = 0 0x00 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# fsck.hfsplus -y -d /dev/sda7 
** /dev/sda7 
** Checking HFS volume. 
   Invalid B-tree node size 
(4, 0) 
** Volume check failed. 
volume check failed with error 7 
    volume type is HFS 
    primary MDB is at block 2 0x02 
    alternate MDB is at block 890878 0xd97fe 
    primary VHB is at block 0 0x00 
    alternate VHB is at block 0 0x00 
    sector size = 512 0x200 
    VolumeObject flags = 0x19 
    total sectors for volume = 890880 0xd9800 
    total sectors for embedded volume = 0 0x00 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# mount /dev/sda6 /mnt/sda6 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# mount /dev/sda7 /mnt/sda7 
mount: /dev/sda7 ya está montado o /mnt/sda7 está ocupado 
mount: según mtab, /dev/sda7 ya está montado en /mnt/sda7 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# umount /mnt/sda7 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# mount /mnt/sda7 
mount: no se puede encontrar /mnt/sda7 en /etc/fstab o /etc/mtab 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# mount /dev/sda7 /mnt/sda7 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# mount /dev/sda8 /mnt/sda8 
mount: /dev/sda8 ya está montado o /mnt/sda8 está ocupado 
mount: según mtab, /dev/sda8 ya está montado en /mnt/sda8 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# umount /mnt/sda8 
umount: /mnt/sda8: device is busy. 
        (In some cases useful info about processes that use 
         the device is found by lsof(8) or fuser(1)) 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# mount /dev/sda9 /mnt/sda9 
mount: debe especificar el tipo de sistema de archivos 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# man mount 

[1]+  Detenido                man mount 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# mount -t reiserfs /dev/sda9 /mnt/sda9 
mount: wrong fs type, bad option, bad superblock on /dev/sda9, 
       missing codepage or helper program, or other error 
       En algunos casos se encuentra información en syslog, pruebe 
   dmesg | tail   o algo parecido 

root@casa-VirtualBox:/mnt/sda8/carpetaprueba# cd ~home 
bash: cd: ~home: No existe el archivo o directorio 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# ls 
IE7-WindowsXP-x86-esn.exe 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# pwd 
/mnt/sda8/carpetaprueba 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# cp /home/casa/Escritorio/INFORMATICA.pdf /mnt/sda6 /mnt/sda7 /mnt/sda8 
cp: se omite el directorio «/mnt/sda6» 
cp: se omite el directorio «/mnt/sda7» 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# cp /home/casa/Escritorio/INFORMATICA.pdf /mnt/sda6 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# cp /home/casa/Escritorio/INFORMATICA.pdf /mnt/sda7 
root@casa-VirtualBox:/mnt/sda8/carpetaprueba# 

The summary:

In Ubuntu, btrfs fsck deleted the files I had saved while restoring the partition image in Clonezilla.
The files in the HFS partition and in the HFS+ partition remain.
fsck_hfs  recognizes the HFS partition as stable, but fsck.hfsplus not.
fsck_hfs  recognizes the HFS+ partition as stable, but fsck.hfsplus not
I can't mount the reiser4fs
I can currently write and read in the next partitions: sda6, sda7, sda8: That is: btrfs, HFS, HFS+


Regards,

videoclock

6

Re: [closed] Growing HFS filesystems

Thanks for posting all of your steps.

It would be helpful to know if the file system size is similar to the size of the containing partition.  Since you increased the partition sizes from 250MB to 500 MB, are the file system sizes also similarly grown?

You might try using the "df -k" command to view the file system usage.

7

Re: [closed] Growing HFS filesystems

That's the bash output:

root@casa-VirtualBox:~# mount /dev/sda6 /mnt/sda6
root@casa-VirtualBox:~# mount /dev/sda7 /mnt/sda7
root@casa-VirtualBox:~# mount /dev/sda8 /mnt/sda8
root@casa-VirtualBox:~# mount /dev/sda9 /mnt/sda9
mount: debe especificar el tipo de sistema de archivos
root@casa-VirtualBox:~# df -k
S.archivos         Bloques de 1K   Usado    Dispon Uso% Montado en
/dev/sda1              6092544   5177580    605412  90% /
none                    248648       244    248404   1% /dev
none                    254244      1108    253136   1% /dev/shm
none                    254244       216    254028   1% /var/run
none                    254244         0    254244   0% /var/lock
/dev/sda6               262144       736    261408   1% /mnt/sda6
/dev/sda7               255988     33504    222484  14% /mnt/sda7
/dev/sda8               257024     19128    237896   8% /mnt/sda8
root@casa-VirtualBox:~# 

I suspect that the files in the btrfs filesystem were not after the image restoring because Clonezilla doesn't support btrfs filesystem currently. Maybe with "dd" utility instead of Clonezilla?

Regards

8

Re: [closed] Growing HFS filesystems

It appears to be just as I suspected.  When the file systems were restored, these remained the same size as before 250MB.  The file systems did not grow to 500MB.

Hence it would appear that the steps do not grow file systems to fit the partition upon restoration.