A manual fsck (Solved)

Questions about applications and software
Forum rules
Before you post please read how to get help
Post Reply
User avatar
Bob M
Level 4
Level 4
Posts: 440
Joined: Sat Jan 28, 2017 9:54 pm
Location: New Zealand

A manual fsck (Solved)

Post by Bob M »

A mates computer is bringing up a message upon boot (The root file system on /dev/sda1 requires a manual fsck.)

How does one do this given that Mint hasn't started so there is no Terminal even if I knew the commands. :D

Mint 18.3

Thanks.
Last edited by Bob M on Tue Nov 27, 2018 1:03 am, edited 1 time in total.
User avatar
WharfRat
Level 21
Level 21
Posts: 13906
Joined: Thu Apr 07, 2011 8:15 pm

Re: A manual fsck

Post by WharfRat »

You can boot the live session (installation media) and sudo fsck -fvCy /dev/sda1 in the terminal.
ImageImage
User avatar
phd21
Level 19
Level 19
Posts: 9976
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: A manual fsck

Post by phd21 »

HI "Bob M",

I just read your post and the good replies to it. Here are my thoughts on this as well.

If I am not mistaken, you can boot into Advanced Options then Recovery Mode and run the "fsck" disk check there, then select "Root" console, login and type in reboot...

As was already stated, you can also boot up any live installation edition of Linux Mint and run a console terminal command, or bring up "GParted" partition manager or "Disks" and run it from either of these. If gparted or disks (gnome-disk-utility) are not installed, then install them which works on the live Linux Mint too.

Hope this helps ...
.
"Disks" - Check and or Repair file system
"Disks" - Check and or Repair file system
.
"GParted" partition manager - check and repair file system
"GParted" partition manager - check and repair file system
Phd21: Mint 20 Cinnamon & xKDE (Mint Xfce + Kubuntu KDE) & KDE Neon 64-bit (new based on Ubuntu 20.04) Awesome OS's, Dell Inspiron I5 7000 (7573) 2 in 1 touch screen, Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram, Intel 4 Graphics.
a-bentofreire
Level 2
Level 2
Posts: 61
Joined: Sat Jan 14, 2017 4:02 am

Re: A manual fsck

Post by a-bentofreire »

Recently, I'm also receiving this message, and failure to boot, and I have been using MInt for years without problems.
In my case, it fails to boot, but the OS it provides a basic shell to run commands.
fsck isn't listed on the list of available commands, however it's available as a command.
I run `fsck /dev/sd5` and it fixes the device errors, and afterwards I'm able to boot again, in some cases some files are corrupted.
As I mention, I never had this problem for years, only in the recent version of Mint and Kernel.
User avatar
Bob M
Level 4
Level 4
Posts: 440
Joined: Sat Jan 28, 2017 9:54 pm
Location: New Zealand

Re: A manual fsck

Post by Bob M »

Thanks Guys, problem fixed. :D

You were all right, with slight variations, and the one I managed to find before the replies started coming in was was that of Sir Charles back in July. Worked a treat and everything is running again.

A-bentofreire: I dumped Win10 a couple of years ago, installed Mint 18, and never looked back.

However, this is a new installation of 18.3 on a new computer belonging to a friend, which I hope isn’t signalling things to come. :(

I sometimes get asked by other Linux users why I don’t update, and my response is always “It ain’t broke so I ain’t fixing it!”
User avatar
WharfRat
Level 21
Level 21
Posts: 13906
Joined: Thu Apr 07, 2011 8:15 pm

Re: A manual fsck (Solved)

Post by WharfRat »

To keep the filesystem clean you can setup sudo tune2fs -c35 /dev/sd?? which will run fsck during boot after 35 mounts.

Replace /dev/sd?? with the partition e.g., /dev/sda1
ImageImage
User avatar
phd21
Level 19
Level 19
Posts: 9976
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: A manual fsck (Solved)

Post by phd21 »

Hi "Bob M",

I just read your updated posts and more of the good replies to it. Here are more of my thoughts on this as well.

I.) Linux and Linux Mint have the "fsck" disc check built-in to the boot menu options without having to install or run anything else or booting to another disc, see screenshots below.

Unfortunately, recent versions of Linux Mint do not always show the boot menu which can be changed to show during boot if you want that. In order to access the boot (Grub) menu during power on or reboot (restart) if it is not showing, you can hold down a shift key, or the Esc key, or the spacebar key. Once you are in the boot menu, click Advanced Options, and then Recovery Mode, and you will see the "fsck" option, run that, after about a minute or less hit enter, then select "Root", login, type in "reboot" and then login as normal.

II.) I have only seen that "run fsck" message on drives that are going bad or where there have been power outages causing a reboot or where the computer has been forcibly restarted. Keep in mind that most mechanical hard drives (HDD) only last about 5 years (some much less and some longer).

I would install and run the "smartmontools" drive software on all computers including yours and your mates (friends, family, etc..), see instructions below. Also very highly recommend getting, installing, and using an SSD (solid state drive) as they are very reasonably priced now and readily available if you and your mates have not already done that; also the speed performance improvement is incredible over the older mechanical HDD drives.

* Highly recommend Installing "smartmontools", "gsmartcontrol", "smart-notifier" from the "Synaptic Package Manager (SPM)" or using the console terminal command below. Test your drive and your mates drive.

Code: Select all

sudo apt install smartmontools gsmartcontrol smart-notifier
Good posts: Is it a good idea to enable S.M.A.R.T. on external HDDs? Yes...
viewtopic.php?f=90&t=265869&hilit=smartctl

GSmartControl not working - Linux Mint Forums
viewtopic.php?f=47&t=277195&hilit=smartmon

Monitor SATA and SSD Health with SMART
https://www.linux.com/learn/intro-to-li ... alth-smart

SMART tests with smartctl - Thomas-Krenn-Wiki
https://www.thomas-krenn.com/en/wiki/SM ... h_smartctl


* Recommend checking the computer Bios to make sure SMART is enabled (usually is) and if using SATA drive(s), as most newer computers do, to make sure SATA Settings are using AHCI.

Linux Command To Find SATA Link Speed Such as 1.5 / 3.0 / 6.0 Gbps [ Hard Disk ] - nixCraft
https://www.cyberciti.biz/faq/linux-com ... ink-speed/

Code: Select all

dmesg | grep -i  ahci | grep -i --color Gbps

Code: Select all

dmesg | grep -i sata | grep 'link up'
Has good info and sample Bios pictures
- Obviously, ignore the MS Windows instructions for Linux Mint users -> see method 2 safe to change.
How to Enable AHCI Mode for SATA in BIOS without Reinstalling Windows
https://hetmanrecovery.com/recovery_new ... indows.htm



* How to force fsck to check filesystem after system reboot on Linux - LinuxConfig.org
https://linuxconfig.org/how-to-force-fs ... t-on-linux

4 Tools to Manage EXT2, EXT3 and EXT4 Health in Linux
https://www.tecmint.com/manage-ext2-ext ... -in-linux/

3 Useful GUI and Terminal Based Linux Disk Scanning Tools
https://www.tecmint.com/linux-disk-scanning-tools/

Hope this helps ...
.
. These screenshots are from another article, but show the boot menu and "fsck".
.
Bootup menu for Linux - Screen1 - Showing Advanced Boot Menu option
Image
.
Bootup menu for Linux - Screen2 - showing Recovery Mode option
Image
.
Bootup menu for Linux - Screen3 - shows the "fsck" option among other options
Image
.
Bootup menu for Linux - Screen4 showing the Root prompt just type in reboot and hit enter
*** do not run the console commands at bottom of this screenshot ***
Image
.
.
Example Dell Bios SATA options AHCI
Example Dell Bios SATA options AHCI
Phd21: Mint 20 Cinnamon & xKDE (Mint Xfce + Kubuntu KDE) & KDE Neon 64-bit (new based on Ubuntu 20.04) Awesome OS's, Dell Inspiron I5 7000 (7573) 2 in 1 touch screen, Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram, Intel 4 Graphics.
User avatar
Bob M
Level 4
Level 4
Posts: 440
Joined: Sat Jan 28, 2017 9:54 pm
Location: New Zealand

Re: A manual fsck (Solved)

Post by Bob M »

Thanks very much phd21 for taking the time to present such a comprehensive appraisal of the fsck function.

I’ve saved it, and bookmarked it for future reference, and I’m sure others will be equally appreciative of your efforts.

Thanks again,

Bob
User avatar
phd21
Level 19
Level 19
Posts: 9976
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: A manual fsck (Solved)

Post by phd21 »

Hi "Bob M",

You are welcome from all of us that replied...
Phd21: Mint 20 Cinnamon & xKDE (Mint Xfce + Kubuntu KDE) & KDE Neon 64-bit (new based on Ubuntu 20.04) Awesome OS's, Dell Inspiron I5 7000 (7573) 2 in 1 touch screen, Dell OptiPlex 780 Core2Duo E8400 3GHz,4gb Ram, Intel 4 Graphics.
Post Reply

Return to “Software & Applications”