What's new

filesystem script skipping checks

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Swistheater

Very Senior Member
Mon Feb 13 19:00:37 EST 2017 Unknown filesystem type on /dev/sda1 - skipping check.

Mon Feb 13 19:00:45 EST 2017 Unknown filesystem type on /dev/sdb1 - skipping check.

Mon Feb 13 19:00:44 EST 2017 Unknown filesystem type on /dev/sda1 - skipping check.

Sat Apr 21 21:01:34 DST 2018 Unknown filesystem type on /dev/sdb1 - skipping check.

Mon Feb 13 19:00:42 EST 2017 Unknown filesystem type on /dev/sdb1 - skipping check.

Mon Feb 13 19:00:48 EST 2017 Unknown filesystem type on /dev/sda1 - skipping check.
---------------------------------------------------
 
Mon Feb 13 19:00:37 EST 2017 Unknown filesystem type on /dev/sda1 - skipping check.

Mon Feb 13 19:00:45 EST 2017 Unknown filesystem type on /dev/sdb1 - skipping check.

Mon Feb 13 19:00:44 EST 2017 Unknown filesystem type on /dev/sda1 - skipping check.

Sat Apr 21 21:01:34 DST 2018 Unknown filesystem type on /dev/sdb1 - skipping check.

Mon Feb 13 19:00:42 EST 2017 Unknown filesystem type on /dev/sdb1 - skipping check.

Mon Feb 13 19:00:48 EST 2017 Unknown filesystem type on /dev/sda1 - skipping check.
---------------------------------------------------


It's a known limitation with the script and identifying drive types. If you are using ext* drives you can replace "/jffs/scripts/disk-check" with the following contents;

Code:
#!/bin/sh

CHKCMD="e2fsck -p"
logger -t amtm "Running disk check '$CHKCMD' on $1"
printf "\n$(date) Starting '$CHKCMD $1'\n" >> /jffs/amtm-disk-check.log
e2fsck -p "$1" >> /jffs/amtm-disk-check.log 2>&1
logger -t amtm "Disk check done on $1"
 
so just erase every thing and place this in the scripts... would this mess up it being able to check other file system types as well I have a mix array of file system types
 
btw this is what is in it now
Code:
#!/bin/sh
# auto-check filesystems during boot
# generated by amtm 1.2

FSTYPE=$(fdisk -l ${1:0:8} | grep $1 | cut -c55-65)

case "$FSTYPE" in
   Linux*)
  CHKCMD="e2fsck -p";;
   Win95* | FAT*)
  CHKCMD="fatfsck -a";;
   HPFS/NTFS)
  CHKCMD="ntfsck -a";;
   *)
  logger -t amtm "Disk check: Unknown filesystem type $FSTYPE on $1 - skipping check."
  printf "\n$(date) Unknown filesystem type $FSTYPE on $1 - skipping check.\n" >> /jffs/amtm-disk-check.log
  exit 1;;
esac

logger -t amtm "Running disk check '$CHKCMD' on $1"
printf "\n$(date) Starting '$CHKCMD $1'\n" >> /jffs/amtm-disk-check.log
$CHKCMD $1 >> /jffs/amtm-disk-check.log 2>&1
logger -t amtm "Disk check done on $1"
 
okay so I replaced it with that. I think I will just set the others to run on a scheduled check since they are the nonessential
 
would this mess up it being able to check other file system types as well I have a mix array of file system types

Can't ever say I've purposely ran the wrong command on a different file-system, I wouldn't recommend it though. I used the edited version because I know all my drives are ext4 and never anything else.
 
okay so I replaced it with that. I think I will just set the others to run on a scheduled check since they are the nonessential
There's nothing to schedule in the amtm disk checker for the reason that you can't do a check on a mounted drive or partition. Hence, the check only runs at boot before the device is being mounted.
 
It's a known limitation with the script and identifying drive types. If you are using ext* drives you can replace "/jffs/scripts/disk-check" with the following contents;

Code:
#!/bin/sh

CHKCMD="e2fsck -p"
logger -t amtm "Running disk check '$CHKCMD' on $1"
printf "\n$(date) Starting '$CHKCMD $1'\n" >> /jffs/amtm-disk-check.log
e2fsck -p "$1" >> /jffs/amtm-disk-check.log 2>&1
logger -t amtm "Disk check done on $1"
@Adamm will your truncated version of the check script work on ext2 or just ext4?
 

Latest threads

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top