DietPi-Drive_Manager | Expand file system button, in case of changed storage

Created on 4 Jun 2018  路  9Comments  路  Source: MichaIng/DietPi

Hello, is it possible to include with DietPi pre-installed the raspi-config tool?

Thanks

Feature Request

Most helpful comment

@467815891a
Ah yeah when switching disk this makes totally sense.
You can currently run the service manually, but be sure the backup on 2nd SD is up-to-date:

/DietPi/dietpi/dietpi-services stop
chmod +x /var/lib/dietpi/fs_partition_resize.sh
/var/lib/dietpi/fs_partition_resize.sh
/DietPi/dietpi/dietpi-services start

I added this to v6.10 milestone. Will add a button to dietpi-drive_manager for file system expansion.

All 9 comments

@symbios24
Thanks for your request.

dietpi-config should include all features of raspi-config and more. For this reason we do not include the latter to reduce redundancy and possible incompatibility of both tools adjusting the same files etc.

If you miss any feature or something is done possibly better in raspi-config, please let us know and we will update the behaviour of dietpi-config accordingly.

Within issue title you name the partition resize I guess? This should be done automatically on 1st boot of DietPi, so nothing to do manually any more. Did this not work somehow? In this case please post output of fdisk -l /dev/mmcblk0 and content of /var/tmp/dietpi/logs/fs_partition_resize.log.

However锛孖 want dietpi-config add "extend rootfs" options like raspi-config.
I use dd command to backup the whole sdcard and restore to a new sdcard.
Now I am having trouble in extend rootfs to fullfill new sdcard.
Who can tell me how to manual extend rootfs in dietpi v6.8...

@467815891a
Ah yeah when switching disk this makes totally sense.
You can currently run the service manually, but be sure the backup on 2nd SD is up-to-date:

/DietPi/dietpi/dietpi-services stop
chmod +x /var/lib/dietpi/fs_partition_resize.sh
/var/lib/dietpi/fs_partition_resize.sh
/DietPi/dietpi/dietpi-services start

I added this to v6.10 milestone. Will add a button to dietpi-drive_manager for file system expansion.

@MichaIng Thanks so much馃榿

I tried the commands but I got the error "Re-reading the partition table failed.: Device or resource busy". Can anyone help?

@DaCodaHUB

Hi,
Which disk are you attempting to resize? RootFS?
Please paste results

df -h

The error is due to the partition table resize, which will not work on a live system with RootFS mounted, although, the filesystem resize should work.

Either way, the resize should not fail on first run. The only factor that might cause a failed resize on RootFS is a hardware issue. Or, you cloned the SD card, in which case we need to add a feature for this.


Notes:

  • RootFS resize must be done during boot (we can use our existing /var/lib/dietpi/fs_partition_resize.sh)
  • All other devices should be achievable via unmount

@DaCodaHUB

Use the following to resize RootFS during boot:

systemctl unmask dietpi-fs_partition_resize.service
systemctl enable dietpi-fs_partition_resize.service
reboot

You can then check the log with

cat /var/tmp/dietpi/logs/fs_partition_resize.log

@MichaIng

I'll pick this one up, as still working on https://github.com/Fourdee/DietPi/issues/1858

I will close this issue in favour of the one linked by Fourdee and as he already added the feature 馃槂.

Was this page helpful?
0 / 5 - 0 ratings