resize2fs error:'Please run 'e2fsck -f /dev/sda1'

I had to shrink the first partition of our server recently but GParted and resize2fs had some problems doing it. There was always the error

Please run 'e2fsck -f /dev/sda1' first.

although I had checked all HDDs right before the attempt to shrink them.

After an hour of searching I found out that the time settings of your system (hardware clock and software clock) have to be correct to let rezise2fs check your last run of e2fsck.

There was no RTC battery installed and so the clocks were wrong. After setting the correct time everything worked :)


Matias Colli wrote on

It's works for me. Matias Colli Perito Informatico Forense A-128

fer wrote on

Thanks, this was my issue.

vitalinvent wrote on

Awesome , its help me! THANKS!

Gabriele wrote on

Worked like a charm! Thanks man, I owe you!

Leave Comment: