LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-16-2019, 05:42 AM   #1
ForumLiker
LQ Newbie
 
Registered: Dec 2019
Posts: 3

Rep: Reputation: Disabled
The file system F2FS is broken


Hello everybody. There was a need to create a swap. There was no free partition, so I decided to create a swap in the file. I did everything according to the instructions https://wiki.archlinux.org/index.php/Swap As a result, it was done:
Code:
dd if=/dev/zero of=/swapfile bs=1M count=4096
chmod 600 /swapfile
mkswap /swapfile
swapon --discard /swapfile
Also added an entry to fstab. swap immediately determined. After a couple of minutes of work, the kde plasma crash. I tried to turn off / restart the PC through the terminal, to which I received that the argument of any of the commands is incorrect. Made a hard reset. After starting the PC I get:
Code:
...
:: Loading keymap...done
:: mounting '/dev/sdb2' on real root
[ 3.279565] F2FS-fs (sbd2): Can't find valid F2FS filesystem in 2th superblock
[ 3.299279] F2FS-fs (sbd2): SIT is corrupted node# 174191 vs 586513
[ 3.299312] F2FS-fs (sbd2): Failed to initialize F2FS segment manager (-117)
mount: /new_root: mount(2) system call failed: Structure needs cleaning.
...
[rootfs ]#_
I tried to run fsck.f2fs /dev/sdb2 through the Linux Mint live mode. What did I get a huge list of damaged blocks for, after which I asked whether to restore files from ./lost_find? Answered Yes. As a result, the recovery failed. I hope there is an opportunity to save my FS.
upd: When asked whether to restore files, answered no, after asking whether to restore the partition - answered yes, then asked whether to restore files - answered no. Posted by Done. The partition is still not mounted, but at startup it now writes:
Code:
...
[ 3.277440] F2FS-fs (sbd2): Can't find valid F2FS filesystem in 2th superblock
[ 3.370489] F2FS-fs (sbd2): Failed to read root inode
....

Last edited by ForumLiker; 12-17-2019 at 12:09 AM.
 
Old 12-17-2019, 06:46 PM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Swapping to a NAND card is a bad idea. It seems obvious that you broke your filesystem beyond repair.

If there is no backup, I would use something like photorec to recover whatever useful data can be found on the card, throw the card away and reinstall the system on a new one. If your computer requires swapping, use an external disk or a computer with more RAM.

My story: My file server used to run regular Centos 6 from a USB key. It took about a year to break similarly to yours. Now I use an old spinning laptop disk I had lying around. No issues for years.
 
Old 12-18-2019, 02:04 AM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,119

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Looks like only (very) recently has f2fs supported native swap. As in 5.3 kernels.

If your data isn't worth backing up prior to you messing around, it isn't worth anything.
 
Old 12-18-2019, 02:20 AM   #4
ForumLiker
LQ Newbie
 
Registered: Dec 2019
Posts: 3

Original Poster
Rep: Reputation: Disabled
Thanks for answers. testdisk destroyed all partitions of the disk, because it does not understand f2fs. reinstalled the system on a new one on btrfs with support for creating snapshots
 
  


Reply


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
LXer: F2FS File-System Merged Into Linux 3.8 Kernel LXer Syndicated Linux News 0 12-22-2012 07:01 PM
LXer: Initial F2FS File-System Results Are Impressive LXer Syndicated Linux News 0 10-21-2012 03:50 PM
LXer: Open-source Flash file system F2FS released by Samsung LXer Syndicated Linux News 0 10-09-2012 12:10 PM
LXer: Samsung Introduces New Linux File-System: F2FS LXer Syndicated Linux News 0 10-05-2012 07:10 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:18 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