LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 12-23-2018, 06:45 AM   #1
jeenuv
LQ Newbie
 
Registered: Aug 2014
Location: Cambridge, UK
Distribution: Linux Mint 20.1
Posts: 23

Rep: Reputation: Disabled
Question Sharing ext4 file system between Cromebook and Linux


I've recently come across some weirdness regarding ext4 file system. This involves a Chromebook and a Linux host, but are essentially Linux systems.

A single ext4 partition was created on a USB drive from a Chrombook (via. chrosh). The Chromebook does recognize the drive when plugged in, is able to read and write etc. - the usual stuff.

However, if were to plug that drive into a Linux machine, mount, and read/write some files, ejects, then then plug that back into Chromebook (some file sharing, essentially), the Chromebook no more recognizes the drive. Not only would it not auto mount, but will print this error when I try to mount it via chrosh:

Code:
mount: /media/removable/foo: wrong fs type, bad option, bad superblock on /dev/sdb1, missing codepage or helper program, or other error.
The weird thing is that the file system is not corrupted nor ivnalid - I can continue to use the drive on a Linux machine, but not on Chromebook. Even weirder, this doesn't happen with ext3.

I've tried it with multiple USB drives, so can't be a problem with the drive itself.

So I guess my question is: how could normal file system operations from a different host turn the disk unusable on a Chromebook?

Happy to provide more info if required. Thanks in advance.

Last edited by jeenuv; 12-23-2018 at 06:47 AM.
 
Old 12-23-2018, 07:01 AM   #2
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,348

Rep: Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336
Sounds like a good chance for some detective work. After making a USB on Chrome, copy it to a second one. Write a file using "echo Hello > /mnt/USB" on each system and compare the differences between the two superblocks using tune2fs and cmp. Post the results back here.

Edit: seems there is a recent report of fs corruption in the 4.19 kernel. What are you running?

Last edited by smallpond; 12-23-2018 at 07:07 AM.
 
1 members found this post helpful.
Old 12-23-2018, 08:39 AM   #3
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,828

Rep: Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243Reputation: 2243
Perhaps there is some ext4 feature that is causing the problem if it is actually used. Run
Code:
tune2fs -l /dev/{X} | grep -E 'features|flags'
(with the appropriate substitution for "{X}") with the newly created filesystem, and then again with the filesystem in a state that the Chromebook will not accept.
 
1 members found this post helpful.
Old 12-23-2018, 09:04 AM   #4
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 24,673

Rep: Reputation: 8105Reputation: 8105Reputation: 8105Reputation: 8105Reputation: 8105Reputation: 8105Reputation: 8105Reputation: 8105Reputation: 8105Reputation: 8105Reputation: 8105
Yes, it looks like a filesystem driver problem. Is there any other way (= other host) to check this drive?
 
Old 12-23-2018, 10:52 AM   #5
jeenuv
LQ Newbie
 
Registered: Aug 2014
Location: Cambridge, UK
Distribution: Linux Mint 20.1
Posts: 23

Original Poster
Rep: Reputation: Disabled
Thanks for your replies. I've done some comparisons on the output of dumpe2fs: when Chromebook is happy to mount the drive, the Journal features shows "(none)". When I mount the drive on my Linux laptop, it seem to amend these features to "journal_64bit journal_checksum_v3". With these journal features, Chromebook no more accepts or mounts the FS when I plug it back.

I ran fsck on the partition just after Chrombook refused, and it displayed clean, so I don't think it's corrupting anything.

Besides, when I format the partition as ext3, the journal features remains on both machines as "(none)".

Do you think the Linux host modifying the journal features could be the problem? I don't see any differences in the dump otherwise, other than super block sizes, check sums, and last mounted paths.
 
Old 12-23-2018, 11:24 AM   #6
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,348

Rep: Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336Reputation: 1336
Normally, the superblock format would not be modified after the FS is created, but due to a bug in the V2 checksum, it automatically gets updated to V3. The change is described here:

https://github.com/endlessm/linux-me...c95abc7caee365

I guess Chrome doesn't have this fix.
 
Old 12-23-2018, 11:34 AM   #7
jeenuv
LQ Newbie
 
Registered: Aug 2014
Location: Cambridge, UK
Distribution: Linux Mint 20.1
Posts: 23

Original Poster
Rep: Reputation: Disabled
FWIW, the Chrome book says that it's 3.8.11, and my Linux host, 4.15.0. Given it's the only difference between dumps, and that the Chrome kernel is rather old, maybe this is the problem indeed. I'll stick to ext3 for now.

I'll mark this thread as solved, then. Thanks for your help!
 
  


Reply

Tags
chromebook, ext4


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to change file system from ext4 journeying to ext4 writeback ? 5883 Linux - Newbie 6 03-10-2014 08:04 AM
[SOLVED] ext4 with "Mount count" > "Maximum mount count" is not fscked catkin Linux - General 3 10-03-2013 07:34 AM
modprobe: Module ext4 not found. no dependencies for kernel module 'ext4' found Aquarius_Girl Linux - Newbie 6 01-25-2012 05:07 AM
Is it safe to format USB flash to ext4 or ext4? joham34 Linux - Newbie 2 01-08-2011 11:58 AM
Mount. Umount. Mount. Umount. Mount. Umount. Mount.. cwizardone Slackware 10 03-22-2007 09:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 04:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration