date int64 1,220B 1,719B | question_description stringlengths 28 29.9k | accepted_answer stringlengths 12 26.4k | question_title stringlengths 14 159 |
|---|---|---|---|
1,594,968,503,000 |
I am seeking a method of getting the crtime of a file in hexadecimal or decimal in unix epoch seconds instead of in a date and clock format and with no additional output.
This command adds additional text at the top of the output ( such as "debugfs 1.42.12 (29-Aug-2014)") that's impossible to remove with grep, sed, et... |
You can use grep with PCRE (-P) to extract the desired portion and use it as input for date:
date --date="$(sudo debugfs .... |& grep -Po '^crtime.*-\s\K.*$')" '+%s'
Or
date --date="$(sudo debugfs .... 2>/dev/null | grep -Po '^crtime.*-\s\K.*$')" '+%s'
For example:
$ date --date="$(sudo debugfs -R 'stat <677051>' /d... | how to get crtime of a file in an ext4 partition as a single number or string |
1,594,968,503,000 |
I'm trying to set up a custom Linux installation on an Intel Atom (Baytrail) based Android tablet, using Qt 5.5 for device creation. The build system is based on the Yocto project and builds an embedded Linux image. In order to run this image on the tablet (which is originally and Android tablet), I'm replacing the bo... |
OK, so it turned out the issue was that not all the partitions were being listed under /dev. The eMMC has 15 partitions on, but only 1 - 7 were listed. I thought that the 1 - 7 were just the ext4 partitions, and that the other partitions (which aren't formatted to ext4) just wouldn't show up there. So when I thought I... | Trying to mount ext4 partition from eMMC gives "Invalid Argument" error |
1,594,968,503,000 |
Recently had a LVM'd CentOS 6.5 install get accidentally cold-shutdown. On bootup, it says that the home partition need fscking:
/dev/mapper/vg_myserver-lv_home: Block bitmap for group 3072 is not in group. (block 3335668205)
/dev/mapper/vg_myserver-lv_home: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY.
...but I gu... |
Run e2fsck -y to say yes to all questions automatically instead of having to manually say yes a million times.
| targeting a specific block with e2fsck to shorten wait |
1,383,063,470,000 |
I had a disk with a full size NTFS partition. I just deleted it and created an EXT4 one.
When it was NTFS, if it wasn't in use (mount but no in use) it was quiet. However now, using EXT4, it is constant reading and I don't know why.
Using EXT3 is fine also.
Any idea?
|
This would have been the "lazy initialization" feature of Ext4 which zeroes out the inode tables on the first mount after creating the file system.
This allows the file system to be created faster, but runs a kernel thread called "ext4lazyinit" in the background. You can confirm if this is happening by running "ps aux... | Constant reading using ext4 |
1,383,063,470,000 |
The other day I had a script error which wrote 4 million small text files to my home directory:
I've accidentally written 4 million small text files to a folder, how best to get rid of them?
I deleted those files, but since then whenever I hit tab to complete a filename or path there's a half second delay before anyth... |
As mentioned in the comments, your home directory itself is huge, and won’t shrink again. Scanning your home directory’s contents will involve reading a lot of data, every single time (from cache or disk).
To fix this, you need to re-create your home directory:
log out, log in as root, and make sure no running proces... | Bash tab completion slow after accidentally writing (but then deleting) millions of files to a directory |
1,383,063,470,000 |
I have a USB stick encrypted with LUKS + Ext4. I have forgotten the password...
However, I know which words will be included in the password and have a list of all permutations of those words. About 10,000 permutations.
Instead of me trying each and every permutation 1 by 1 manually (which will be a long, slow, and ... |
Well, in the most naive case you can roughly do something like
for a in 'fo' 'foo' 'fooo'
do
for b in 'ba' 'bar' 'baar'
do
for c in 'bz' 'baz' 'bazz'
do
echo -n "$a$b$c" | cryptsetup open /dev/luks luks \
&& echo "'$a$b$c' is the winner!" \
&& break 3
... | Automate multiple password enties to decrypted LUKS + Ext4 USB stick |
1,383,063,470,000 |
is it possible to understand , when filesystem was created on disk ( date and time )
we try the following ( on sdb disk )
tune2fs -l /dev/sdb | grep time
Last mount time: Mon Aug 1 19:17:48 2022
Last write time: Mon Aug 1 19:17:48 2022
but we get only the last mount and last write
what we need ... |
Typically a device /dev/sdb contains a partition table, not a filesystem. It's each individual partition that would contain a filesystem. However, since your example uses /dev/sdb itself I'll also use that here.
Using your own tune2fs command and looking at the output:
tune2fs -l /dev/sdb
it's possible to see by insp... | linux + is it possible to understand when filesystem was created on disk |
1,383,063,470,000 |
I have an ext4 formatted disk with thousands of files that are generated automatically and are needed. A few thousand of them are only one byte long, some two bytes. All files in both groups of tiny files are identical.
How much space can I save by locating these, say 1000, files of 1 byte in length, removing each a... |
There are three parts to storing files: the blocks used to store the file contents, the inode used to store the file’s metadata, and the directory entry (or entries) pointing to the inode.
When you create multiple separate files, in the most general case you pay this cost as many times as there are files.
With inline ... | How much space can I save on ext4 by replacing 1000 identical 1-byte files with 999 hard-links and 1 file? |
1,383,063,470,000 |
At the time of Linux installation, i have mentioned only one filesystem (/dev/sda1 -> ext4 -> / ). But for dev, run, proc, sys - Linux is creating addition FS which is inferable from mount.
$ mount
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev... |
The mount output lists the file system types:
/dev is a devtmpfs (a virtual file system exporting device nodes)
/run is a tmpfs (a virtual memory file system)
/sys is a sysfs (a virtual file system exporting kernel objects)
All of these live in memory, not on your drives. man 5 proc tmpfs sysfs will show you the doc... | Does /dev, /run and /sys exist on HDD (if so what is there location if it can be meaningfully traced)? |
1,383,063,470,000 |
I have Debian 10 with the latest Proxmox installed.
2 SSD with:
sda1: EFI
sda2: raid1 (/dev/md0)
sda3: swap
sdb1: EFI (clone of sda1)
sdb2: raid1 (/dev/md0)
sdb3: swap
After an update, I wanted to clone /dev/sda1 to /dev/sdb1 with dd, but I made an error and typed dd if=/dev/sda of=/dev/sdb. I cancelled it with Ctrl+... |
Explaining The Error:
That error does not indicate a problem with a physical disk; loop0 is a loopback device. Which is a block storage device that uses a file on disk as a backing store. A disk within a disk you might say. These loopback disks have their own filesystems and sometimes their own partition tables. So r... | EXT4-fs error on loop0 |
1,383,063,470,000 |
I have a RHEL 9 with an ext4 fs
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 1258291199 1258289152 600G 83 Linux
it has been requested it be ext4 with Inodes for 100,000,000 files +
I thought I could just run mkfs.ext4 -N 2000000000 /dev/sdb1
to get more than enough inodes however ... |
Why -N 2000000000? Your question says your target is around the 100 million mark, not the 2000 million mark - you're asking for 20x more inodes than you need. Fix that and you might get a reasonable result.
However, there is a bigger issue here with regard to file size. Although at a minimum of 1kB/file you're going t... | Setting up ext4 filesystem to accomodate 100,000,000 files iNode issues |
1,383,063,470,000 |
Today I learned that there had been a faulty Debian kernel version which caused ext4 data corruption (bug 1057843) in December 2023.
Searching through the /var/log/aptitude and /var/log/apt logs, I noticed that the faulty kernel version was installed for one full day by /usr/bin/unattended-upgrade .
The chronology:
0... |
As far as I understand, you are safe from this bug.
The only way to have the ext4 module changes to apply to the currently running non-buggy kernel would have been to first unmount all ext4 filesystems, then unload the old ext4 module and force-load the module from the buggy kernel version (overriding the kernel's pre... | Debian file corruption bug possible without reboot after unattended kernel update? |
1,383,063,470,000 |
From man chattr
When a file with the 'A' attribute set is accessed, its atime record
is not modified. This avoids a certain amount of disk I/O for laptop
systems.
However when I am remounting a filesystem with the noatime mount option:
[root@localhost ~]# mount -o remount,noatime /dev/sdb1 /newfs/
creating a f... |
Yes, this is expected: the two behaviours are orthogonal. Setting the A attribute on a file ensures that its access time is never updated, irrespective of mount options. Mounting a file system with noatime ensures that no access time is updated on it, irrespective of file attributes.
Mounting a file system with a give... | Setting noatime via mount options vs no atime updates (A) file attribute |
1,383,063,470,000 |
I've been Googling about, and it seems the answer is 'no' from anecdotal reports for gparted. However does this apply to parted as well?
I'm not talking about risk factors here involved by inputting the wrong partition, fat fingering a button, power cuts etc - I mean direct effects only.
How does parted know how much ... |
gparted and parted may have similar names but they do (very) different things. gparted is a standalone software with a distinct set of features and explicitely not (just) a GUI frontend to parted, even though it's labelled as such in many places.
How does parted know how much 'space' is available?
parted does not kn... | Does parted have the same functionality as gparted for shrinking an ext4 partition? |
1,383,063,470,000 |
Suppose there's a hard drive /dev/sda, and both that:
/dev/sda1 is a single ext4 partition taking up the whole disk, and it's mostly empty of data.
dumpe2fs -b /dev/sda1 outputs the badblocks list, which in this case outputs single high number b representing a bad block near the end of /dev/sda; b is fortunately ... |
GParted doesn’t take any ext2/3/4 badblocks list into account; I checked this by creating an ext4 file system with a force bad block, then moving it using GParted. Running dumpe2fs -b on the moved partition shows the bad block at the same offset.
The result is 2, so the bad block ignored by the file system no longer c... | Does gparted make good use of badblocks lists? |
1,383,063,470,000 |
Let's say I run rm -Rf on a very large folder with many files and folders of different size, user permissions etc.
I would like to know, does the rm command first accumulate the list of files to delete and only after it scans the whole folder for these files it starts to delete?
or does it actually delete each file a... |
If you run rm -Rf /, rm will output an error message and stop, as specified by POSIX:
if an operand resolves to the root directory, rm shall write a diagnostic message to standard error and do nothing more with such operands.
In other cases, or if you force rm to process / (assuming your version can be forced, e.g. ... | What is the actual sequence of steps during rm -Rf on a very large folder? |
1,383,063,470,000 |
I recently had couple of accidents with my disks formatted to etx4. To be honest, I believe the failure was on my side, because one of them was due to incorrect [manual] unmounting of flash card, and the other was related to electricity switched off. The net effect is I physically lost 128 GB flash card [with money r... |
My main concern is that such damage NEVER happened to disks partitioned to NTFS, whatsoever.
It may have never happened to you, but it has happened. The only filesystems that can claim things like this never happening are those that have never been exposed to such conditions. Even BTRFS and ZFS, which are both des... | Is ext4 filesystem safe? [closed] |
1,383,063,470,000 |
uname -a gives:
Linux devuan 4.9.0-6-amd64 #1 SMP Debian 4.9.88-1 (2018-04-29) x86_64 GNU/Linux
All filesystems on all disks in this box are ext3 (~15T worth over six disks)
ps -A gives:
...
14684 ? 00:00:00 jbd2/sdc1-8
14685 ? 00:00:00 ext4-rsv-conver
14688 ? 00:00:00 jbd2/sdc2-8
14689 ? 0... |
Since version 4.3 of the kernel, Ext3 file systems are handled by the Ext4 driver. That driver uses workqueues named ext4-rsv-conversion, one per file system; there is no way to get rid of them.
| Can I get rid of "ext4-rsv-conversion" process? |
1,383,063,470,000 |
Is there any way to recover a few specific files from a deleted EXT4 partition. I deleted all partitions on my 480GB SSD. Afterwards, I created a 200 GB NTFS partition (which is mostly empty) and I have about 280 GB still unpartitioned.
I didn't do a "wipe" (or whatever it's called), so it was a quick deletion pro... |
You can use System rescue CD as a live cd
https://www.system-rescue-cd.org/SystemRescueCd_Homepage you'll find the photoRec software in it, to recover lost data.
You can also use the soft directly from windows:
www.cgsecurity.org/wiki/PhotoRec
Here some details on how to use photoRec
http://www.cgsecurity.org/wiki/Pho... | Recover specific files from deleted EXT4 partition |
1,383,063,470,000 |
I have an ext4 formatted partition, namely /dev/sdc1. I did not format it but somehow parted reports this partition as an unknown file system. Is there a way to mark this partition as ext4 again without formatting, so that I can try to rescue remaining files as much as possible?
|
For Linux, the partition type identifiers are almost entirely cosmetic: in particular, the filesystem repair tools certainly won't require the partition type to be correctly specified in the partition table.
If you point an ext4 filesystem recovery tool at a partition, it will do its best to find and fix an ext4 files... | How to recover / restore an “ext4” partition? |
1,383,063,470,000 |
I'm studying the Ext4 filesystem and am confused by the 128 byte inode size because it appears to conflict with the last metatdata value it stores which is supposed to be offset at byte 156.
In this documentation it states that inodes are 128 bytes in length. I called dumpe2fs on an unmounted /dev/sdb1. The dumpe2fs... |
it states that inodes are 128 bytes in length
No. It states that [emphasis mine]:
[…] each inode had a disk record size of 128 bytes. Starting with ext4, it is possible to allocate a larger on-disk inode at format time for all inodes in the filesystem to provide space beyond the end of the original ext2 inode. The ... | Why do inode offset values appear to exceed inode size? |
1,383,063,470,000 |
How/why did fstrim trim more space than I have free?
$ df -h /
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/drystone_2019-debian 93G 84G 4.6G 95% /
$ sudo fstrim -v /
/: 8.8 GiB (9395548160 bytes) trimmed
$ uname -r
4.19.0-6-amd64
$ head -n1 /etc/os-release
PRETTY_NAME="Debia... |
Q: df -h - "Used" space + "Avail" Free space is less than the total "Size" of /home
A: By default, ext2/3/4 filesystems reserve 5% of the space to be useable only by root.
(and the reserved space is not shown in "Available").
| How/why did fstrim trim more space than I have free? |
1,383,063,470,000 |
Using debugfs -R 'stat <inode_nr> ' /dev/sda1 returns a result where there is a field crtime which i believe represents the creation date of a file pointed to by inode numbered inode_nr. I use this on an ext4 fs.
I know that the inode stores access_time, modification_time and change_time but not birth of a file
So m... |
If the filesystem records file creation time (Not all do), it's stored in the inode along with the rest of the file metadata like modification and change times. It can be retrieved with the fairly recently added statx(2) system call in the stx_btime field of the struct statx that it populates. Note that there's no eas... | Where is the file creation time (birth) stored in linux? |
1,383,063,470,000 |
I can't understand, why there is so long time delay between these two lines in my dmesg log.
[ 2.089039] hid-generic 0003:1EA7:2001.0003: input,hiddev0,hidraw2: USB HID v1.10 Mouse [WFDZ Gaming Keyboard] on usb-0000:00:14.0-14/input1
[ 2.752704] clocksource: Switched to clocksource tsc
[ 33.501004] EXT4-fs (sd... |
Debian initramfs-tools version 0.129 (and later) added a 30s wait for the resume device (used for suspend-to-disk aka hibernate) to appear. Previously, it'd check once and if it didn't find it, continue. Now instead it keeps trying to 30s. That is in general a good thing; it makes resume from suspend-to-disk much more... | Long system startup |
1,383,063,470,000 |
Trying to get behind the internals and secrets related to understanding ext4 I was reading on the ext4.wiki. The author(s) did their best to show the structures used (such as the layout/struct of an ext4_inode) yet somtimes it seems they run out of ideas.
Looking up what l_i_version is used for I found this:
l_i_vers... |
don_crissti found the original patch submission for the extension of inode versions to 64 bits, which explains the use of these fields:
inode->i_version = le32_to_cpu(raw_inode->i_disk_version);
if (EXT4_INODE_SIZE(inode->i_sb) > EXT4_GOOD_OLD_INODE_SIZE) {
if (EXT4_FITS_IN_INODE(raw_inode, ei, i_version_hi))
... | What does l_i_version in an ext4 inode actually do? |
1,383,063,470,000 |
I made a partition of 5 GB -> /dev/sdd2
then made a filesystem sudo mke2fs -N 700 -t ext4 -L test2 /dev/sdd2
and set root reserved space to 0 sudo tune2fs -r 0 /dev/sdd2
sudo dumpe2fs -h /dev/sdd2 shows:
Filesystem volume name: test2
Last mounted on: <not available>
Filesystem UUID: 64f07e45-910b-... |
So, the sad part up front: I can't tell you in each detail why the filesystem is structured the way it is – multiple decades of experience, features and bug fixes flow into that, and the ext2/3/4 source tree in the kernel source is not exactly small.
I will still try to address the explicit questions you ask:
Where a... | calculate df available space [duplicate] |
1,383,063,470,000 |
Due to an accident specifying a block device, the first 32GB of a 4TB ext4 filesystem on a SATA disk was overwritten by the dd command with the contents of a USB flash drive.
fdisk -l /dev/sda reports the following:
Disk /dev/sda: 3.7 TiB, 4000787030016 bytes, 7814037168 sectors
Units: sectors of 1 * 512 = 512 bytes
S... |
You should make a full "dd" copy of the partition to another device, just for safekeeping in case something goes wrong.
In general, e2fsck should be able to recover from such an issue, subject to loss of the overwritten metadata. The superblock, root directory, journal, and other metadata would be lost. However, the... | First 32GB of a 4TB ext4 filesystem overwritten. How to recover? |
1,383,063,470,000 |
I'm formatting an external hard drive with gparted.
The original NTFS read 232.28 MB used.
Now, with Ext4, it reads 1.92 GB used.
Questions:
Why?
Is there a better file system I should use for external drives?
(This drive will only be used with linux computers. )
Thank you!
|
I assume those "used" values are both for a freshly-created, empty filesystem of the same size, and that's where your confusion comes from. Those "used" values suggest that the actual size of the filesystem on the external drive is probably quite large (say, more than 1 TB?).
On a freshly-created empty filesystem, the... | Formatting the same drive with gparted: original NTFS=232.28MB used | Ext4= 1.92 GB used Why? |
1,383,063,470,000 |
As the title states, grub is unable to recognise my ext4 partition:
GNU GRUB version 2.06-3~deb11u5
Minimal BASH-like line editing is supported. For the first word, TAB
lists possible command completions. Anywhere else TAB lists possible
device or file completions.
grub> ls (hd0
Po... |
GRUB2 doesn't currently support the inline_data ext4 feature.
I can't say for sure whether you can disable it at runtime using tune2fs (on an unmounted partition) but you could try.
| grub does not recognise specially-formatted ext4 partition |
1,383,063,470,000 |
According to the mount man page,
Access time is only updated if the previous access time was earlier than the current modify or change time.
However if I do this (ext4 with relatime option(*)):
> date +%T.%N ; dd if=/dev/random of=random.dat bs=1 count=4096 ; date +%T.%N ; stat random.dat
18:52:00.616084761
4096+0 ... |
Since you are not accessing the data blocks (only writing to them) then atime is not updated. If you read the random.dat then the atime will get updated (as long as the relatime criteria is met).
you can see this for looking for calls to file_accessed() in the kernel:
https://github.com/torvalds/linux/blob/master/fs/... | Access time strangeness |
1,383,063,470,000 |
I have a 2tb hard drive containing gpt and a single 2tb partition with ext4 file system. The partition has one 1.5tb file inside it. I want to change the type of file system of this partition from ext4 to exfat without deleting the 1.5tb file. Can I do that without writing a custom program?
|
There is a tool which some people have successfully used to convert Ext4 partitions to exFAT in place, fstransform. Note that the tool doesn’t officially support conversions to exFAT, and I haven’t tried it — but there are apparently reports of it working (with the --force-untested-file-systems flag).
In any case you ... | Change the file system of a partition without deleting its content |
1,383,063,470,000 |
I'm looking on my Debian 11 Server for the easiest way to allocate 100GB of extra space after the /dev/sda1 device in command line.
The sda1 partition is almost full and needs to be resize with the unallocated space.
Here is the structure of my hard drive:
Disk: /dev/sda
... |
The free space is not directly after the sda1 partition so you can't use it, you need to remove (or move, but removing is easier) the swap partition sda5.
Stop the swap using swapoff /dev/sda5
Remove the sda5 partition and the sda2 extended partition.
Resize the sda1 partition. Don't forget to resize the filesystem t... | Extend 100GB of unallocated space on /dev/sda1 device in command line |
1,383,063,470,000 |
how can I add the rest of the 19.5GB from sda2 to vg00-lv01? I tried lvextend but this tells me Insufficient free space: 512 extents needed, but only 0 available.
I'm using Ubuntu 20.4.
NAME FSTYPE SIZE MOUNTPOINT LABEL
sda 20G
├─sda1 ext4 487M ... |
You need to resize both the physical volume and the logical volume within.
pvresize /dev/sda2
lvextend /dev/vg00-lvol1 /dev/sda2 # grow the LV by the amount of free PV
fsadm resize /dev/vg00/lvol1 # grow the FS within the LV
| Extend LVM on Ubuntu 20.4 |
1,625,998,088,000 |
I have a directory which is write-intensive (/home/user/project/.comp, used by the compilation tools), is there a way to buffered the writes only for this directory? (every one hour or at shutdown)
I use ArchLinux with ext4 on a SSD.
|
Depending on the size of the directory and memory available, you might be able to create a ramdisk of suitable size, then mount it in "project/.comp".
A cron job and a shutdown task could then rsync it with the real "project/.comp-real".
You might also want to experiment with different file systems (XFS, for example) ... | Mount a directory in buffered write mode |
1,625,998,088,000 |
Many sources, such as https://www.commandlinux.com/man-page/man8/mkfs.ext4.8.html read:
...block-size is heuristically determined by the filesystem size...
What is this heuristic?
In which source file can the calculation be found?
Do all modern HDDs/SSDs (i.e. over 100 GB) cause 4KiB blocks by default with this heur... |
The calculation seems to be quite simple: if the block size is not selected by user it defaults to page size (so 4096) or logical sector size of the device if it's bigger than page size (there are few more exceptions, but this should cover most of the cases).
The e2fsprogs source is available here and the code that se... | Do almost all ext4 filesystems have 4KiB blocks? |
1,625,998,088,000 |
I have performed a rsync between two folders:
rsync -avzh /mnt/folder1 /mnt/folder2
(folder1 was /dev/sdb and folder2 was /dev/sdc, both ext4 partitions)
Then I have unmounted folder1 and I made a mistake and I mounted /dev/sdc directly over /mnt with:
mount /dev/sdc /mnt
When in fact I wanted to mount /dev/sdc over... |
This is, to prevent data loss !
Run the following command, to see what process prevents unmounting. I am assumimg, that you skipped the partition on the dev to type less:
lsof | grep '/dev/sdc'
Close your work or end the given processes and unmount again. You cal also see, what files are still open with:
fuser -u /mn... | Mount directly over /mnt by mistake |
1,625,998,088,000 |
So I'm making some kind of research on EXT4 checksums.
I found this page and tried to calculate checksum by myself. I've started with Superblock since it is sounds pretty simple: "The entire superblock up to the checksum field".
But it does not work: I can't get the same result as the superblock.
For this task I wr... |
OK. I've got the answer from Reddit (nightbladeofmalice). This man noticed that checksum of the raw superblock without checksum field (0x12cec801) will give reversed (in big-endian) original checksum if you subtract it from 0xFFFFFFFF:
ORIGINAL SUPERBLOCK:
00c0390000cae600198a0b008f99a400e8a535000000000002000000020... | EXT4 CRC32C checksum algorithms are badly documented |
1,625,998,088,000 |
What I understand about it is its "Zero fill on demand" extent. That means file system doesn't allocate write data to the file but it just gives us ZFOD extent and when an application tries to read/write the data it just fills out data zeros and then performs read/write [source].
My questions are:
Is my above underst... |
You must consider two things:
whether or not there is space allocated for the data, and
whether or not there is data actually written.
If a file has no data and no space allocated for it, you get an end-of-file indication if you attempt to read it. If you write to it, the filesystem must allocate space at the time o... | What are ZFOD extents? |
1,625,998,088,000 |
we have Beaglebone black based custom board,
we have busybox shell including coreutils.
busybox version is BusyBox v1.20.2 (2017-10-16 16:39:36 EDT)
now we wanted to check the inode usage in each partition,
So when I run df -i I get following output
# df -i
Filesystem Inodes Used Available Use% Mount... |
I looked at the buglist of busybox but did not find any reference of my error.
Fact that busybox df is working as expected in my ubuntu machine, I looked at the busybox configuration.
Initially I was enabling below two configs only,
CONFIG_DF=y
CONFIG_FEATURE_DF_FANCY=y
And with that I was not able to get expected ou... | df from busybox shows different number of inodes than that of tune2fs |
1,625,998,088,000 |
I had an external hard drive that I mounted internally. It came formatted with NTFS, and I wanted to move to ext4. So I copied everything I wanted to keep onto other drives, created a brand new partition table (GPT) with a single ext4 partition, and now I'm trying to copy everything back. I'm using rsync -a --info=... |
This looks like a hardware issue, rather than a kernel bug. You can try the following:
re-seat the SATA cable
use another SATA cable
run SMART diagnostics (the self-tests, see smartmontools)
run a destructive badblocks scan
If you have a spare drive or computer you could also try switching (use another drive in the ... | Filesystem errors when restoring many files |
1,625,998,088,000 |
I continuously get these messages upon boot:
[ 17.806441] EXT4-fs (sda1): re-mounted. Opts: (null)
[ 157.196550]
postgres (1297): /proc/1297/oom_adj is deprecated, please use
/proc/1297/oom_score_adj instead.
As you can see from the time differences, this is a massive delay! How would I fix this? This happens on... |
The issue was found, by using the application bootchart A graph was formed of all the start up processes, found within it was a large 2 minute sleep process!
This 2 minute sleep was found within /etc/init/failsafe.conf <- this delay is meant to echo out to the terminal, though it did not. by modifying the script i man... | Boot delay errors? |
1,625,998,088,000 |
I previously had a grub bootloader with crunchbang and win7. Since then I reinstalled win7 which now boots it automatically. I stuck in a Debian install CD that brings me to the stage in the above image. The highlighted logical ext4 partition is my existing Debian installation. If I change the settings to make it boo... |
If I'm not mistaken, you don't have to set the partition to bootable. I run only dual-boot machines, and have never done this.
Do you have a particular reason for doing so?
| Reinstalling Debian: ext4 partition is not primary |
1,625,998,088,000 |
I have a question which is slightly programming related, but it mostly relates to how ext4 works.
I have a program which writes 128MB to a file with changing random aligned offsets. I write 256KB every write call. Now the speed results are significantly different between the two devices.
I have /dev/sda and /dev/sdb b... |
Since this is a little bit too long for a comment here it goes...
There are two things that got me intrigued:
First of all, /dev/sda and /dev/sdb are two different physical drives, otherwise we would be talking about /dev/sda1 and /dev/sda2. So if we are talking about different physical drives their performances may ... | writing to ext4, 8GB partition vs 512MB partition |
1,625,998,088,000 |
This question is following Unable to mount /home/ partition after reinstalling grub after reinstalling windows 7 where the diagnostic was that installing windows 7 deleted my /home partition, lovingly called /dev/sda3.
Since almost nothing have been done with this computer since the incident, we can expect that the co... |
Right off the bat make a dd disk image of the drive, and work with that instead of the drive itself. That lets you experiment.
dd if=/dev/sda3 bs=1M > sda3.img
Beyond that I'm not sure. I'd hit google. Might look at it later.
edit; http://www.cgsecurity.org/wiki/TestDisk looks promising.
| how to restore a logical partition to its original ext4 format |
1,625,998,088,000 |
Let's assume I was very unlucky and ran out of inodes in my ext4 filesystem but left with enough free space.
Inode usage is 100%, but it has 50% disk free space.
How can I resolve it?
|
One option is to recreate your filesystem specifying bytes-to-inode ratio with -i option.
Backup all of your data to another disk.
List your filesystems and find the one you want to modify:
$ df -h
assuming that filesystem is /dev/sdX and is mounted on /mnt/mountpoint.
Unmount that filesystem:
$ umount /mnt/mountpo... | Inode limit reached with free space available |
1,625,998,088,000 |
I am looking for a method to read/write an ext4 partition from a Windows 10. Both partitions are on the same physical hard drive on a dual boot system. That means, that NFS wouldn't be sufficient. Are there open tools to achieve that?
Cheers, Jens
|
I don't know of any FOSS drivers that work with recent versions of Windows 10/11.
There are claims that ext2fsd still works, but it stopped working reliably for me several years ago and I wouldn't want to trust it with my data.
There are commercial offerings such as the one from Paragon. I've not used this at all.
Fi... | Need full access to ext4 file system from Windows 10 |
1,625,998,088,000 |
I have an external drive with an ext4 partition /dev/sda1 I use for my local borg backups.
It is simply plugged in via usb port, and, mounted with an fstab generated systemd automount entry. I ran a backup yesterday in the evening without any errors, and this morning, I plugged it in, it was not recognized anymore. Th... |
My first assumption would be a faulty case, particularly as you've got pluggable USB involved. Check that it's plugged in properly (both ends of the cable) and there's sufficient power.
I would also check the partition table, which you added to your question. Unfortunately it too shows a faulty read from the device, w... | Recovering an ext4 partition |
1,625,998,088,000 |
Preface (my 1st attempt ended badly): Fstab adding data=journal crashed my Linux' ext4 upon boot, how to fix?
I can't find some reliable step-by-step instructions on How to enable data=journal ext4 fs mode? (It is my root file system.)
Can anyone help? Thank you!
OS: Linux Mint 21.1 Cinnamon
Here is the tune2fs dump... |
Since this is your root filesystem, adding the mount option in /etc/fstab would pose a bit of a chicken-vs-egg problem: the system would need to know the mount option before starting to mount the root filesystem, but the /etc/fstab file cannot be read until the root filesystem is already mounted.
That's why there is a... | How to enable data=journal ext4 fs mode? |
1,625,998,088,000 |
I have a log file on a CentOS system that is taking up 700MB of space (seen using ls), but when I run the df -h command, it shows that only 200MB of space is being used on the file system (ext4).
What could be causing this discrepancy?
Is it possible for a file to take up more space than is being reported by df, and i... |
ls -l shows the apparent size of the file, i.e. how much data can be read from the file. du shows the amount of space the file actually occupies on disk.
In your case, the log file is sparse: it contains close to 27MiB of actual data, and around 650MiB of blocks which are all zeroes. The way the file was written resul... | Discrepancy between size of log file and space reported by df on CentOS 6.6 |
1,625,998,088,000 |
Im using RHEL 8.7
I've added new HD nvme0n2 to my linux and created partititions successfully
the output of lsblk -f
NAME FSTYPE LABEL UUID MOUNTPOINT
nvme0n2
├─nvme0n2p1
│ xfs 5d966f3d-7aca-4f06-bf74-aa32d97aba76
└─nvme0n2p2
... |
You can’t mount the device as a whole, you need to mount individual partitions:
sudo mount /dev/nvme0n2p1 /mnt/newHardDrive/
| Bad magic number while trying to mount a new hard disk |
1,625,998,088,000 |
I work on an ext4 filesystem. I have doubts about the accuracy of a directory entry regarding the description of a file that I have copied from an NTFS filesystem and that might have spanned some bad sectors (but I am not sure). I now believe the file might have been truncated when copied from its source but that the ... |
So first of all, the untrustworthy filesystem involved here seems to be the originating, not the target file system. If the origin read nonsense, that nonsense gets "correctly" written to the target file, and there's nothing you could do about afterwards – for all that there is in information, that's how the original ... | Is there a way to be sure a file is not truncated compared to the file size stored in the inode table? (Does a dd command do?) |
1,625,998,088,000 |
We have a cluster of flash drives (8TB) mounted on /data as per:
/dev/mapper/vg.data-lv.data on /data type ext4 (rw,relatime)
There are a couple of directories inside /data with one being tmp:
ls -lst /data/
total 1036468
...
1036360 drw-r--r-- 1 secadmin sudo 1061183488 Nov 8 13:10 tmp
...
For some reason this fol... |
As @meuh wrote, this looks like a very large directory, and may have thousands or millions of files and/or subdirectories in it. The GNU ls and rm tools are not very useful for dealing with such large directories, because they try to sort or otherwise process the full output.
You could try "find /data/tmp -print" to g... | RHEL8: Cannot read / modify / delete directory |
1,625,998,088,000 |
Please consider the prior discussion as background to this new question.
I have modified my script and applied the same filesystem options to my USB drive's ext4 partitions using tune2fs, and mount options specified in the fstab.
Those options are all the same as for the previous discussion. I have applied those chan... |
Some ext4 filesystem options may not take effect if specified in /etc/fstab as they require changes to filesystem structures. Some of those can be simply applied with tune2fs while the filesystem is unmounted, but there are some options that may require running a full filesystem check after tune2fs to take effect prop... | EXT4 on USB - how to specify journalling behaviour to be same as for root disk partitions |
1,625,998,088,000 |
Yesterday, a message poped up in Debian, saying that my root partition is full (0 MB free) after I copied a new software under /opt. So I moved the folder back to another partition to temporarily fix the issue.
I freed some space from /dev/nvme0n1p9 using a Debian installation USB, and now try to extend the root parti... |
Does extending the root partition mean pushing partitions located after this one further on the disk, or can I use the unallocated space at the end of the disk and have a root partition split in two?
Yes, it means exactly that. A partition must always be contiguous from the beginning to the end. A LVM logical volu... | How do I resize root partition with UEFI |
1,625,998,088,000 |
The commands I invoke are the following
Create image file
dd if=/dev/zero of=benj.luks bs=1k count=666000
Set up LUKS container
cryptsetup luksFormat benj.luks
Set up loop device and open the LUKS container
cryptsetup luksOpen benj.luks benjImage
Check that the loop device has been set up and mapped
lsblk
... |
cat /sys/block/loop0/queue/physical_block_size
cat /sys/block/loop0/queue/logical_block_size
revealed, that the loop device was mounted as a 4096 bytes block device on which no 2048 byte file system can be created.
hence the solution is to set up the loop device manually and define the sector size at 2048 by utilisin... | Why can mkfs.ext4 not create a 2048 block size file system on 650 MB image file? |
1,625,998,088,000 |
Can someone explains what is defined as the "order of the request" in the buddy block allocation in ext4 file system? It was not possible to find a clear and definite answer. Is there a detailed documentation (a paper or technical report) this stuff? I read the comments in the commits but they are too short and techni... |
Order, as in order of magnitude, refers to the size of the allocation.
| Block allocation in ext4 file system |
1,625,998,088,000 |
This is something I imagine I might have to submit a patch or feature request for, but I'd like to know if it is possible to create a hardlink to a file, that when that hardlink which was not the original file is editted, that it would be copied first before it was actually editted?
Which major filesystem would this a... |
After you create a hard link to a file, there are just two links to one file. While you may remember which link was first and which was second, the filesystem doesn't.
So it is just possible for an editor to determine whether there is more than one link to a file or not. An editor may or may not preserve the link when... | How can I have it so, that when hardlinks which are not the original, are editted, that they would first be copied then editted? |
1,625,998,088,000 |
I am running
$ uname -a
Linux myhostname 4.14.15-041415-generic #201801231530 SMP Tue Jan 23 20:33:21 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
$ lsb_release -a
No LSB modules are available.
Distributor ID: Nitrux
Description: Nitrux 1.1.4
Release: 1.1.4
Codename: nxos
It has a single hard disk with a s... |
From the e2fsck man page (e2fsck is also linked to names fsck.ext2, fsck.ext3 and fsck.ext4):
Note that in general it is not safe to run e2fsck on mounted filesystems. The only exception is if the -n option is specified, and -c, -l, or -L options are not specified. However, even if it is safe to do so, the results pr... | Avoid damaged block in ext4 |
1,625,998,088,000 |
When copy and pasting commands with a space at the end it automatically runs the command without requiring the user to press enter.
This is why I overwrote a large text file with a cp ./newfile ./oldfile command.
How can I restore the oldfile after I aborted the command?
The oldfile is on a hard drive encrypted with V... |
The disk is encrypted so there's absolutely no point in looking on the disk for a plain text string. At best you need to search the mounted filesystem, as this is the decrypted layer, but any writes to it whatsoever are likely to overwrite your deleted data.
Look at the output of this command to identify the filesyste... | How to recover an overwritten file from a mounted VeraCrypt encrypted disk? |
1,625,998,088,000 |
There seem to be many scenarios, I read quite a few, but I caould not find a match for my problem.
I have this gparted view on my system:
I had sda6 swap sit right behind sda5; I moved that sawp space to another disk. Then swapoff and deleted sda6; then extended sda5 to consume the free 8GB... all good so far.
These ... |
gparted and other partitioning software will be funny about extending logical partitions (those within the extended partition sda3) because the underlying extended partition would need to be extended first with the others still inside.
I suggest, you clone your disk to be safe, boot a live image and try gparted from t... | Extending an extended partition with following unallocated disk space |
1,590,335,475,000 |
I have an external backup hard drive that is encrypted using LUKS. As I was re-organising my backups, I copied the data to another encrypted drive and did a kind of "quick wipe" on the original drive by replacing the key in the key slot with random data.
Goal was to use the drive afterwards as a second backup, but at ... |
The problem is the content of the key slot. In order to access the data you need the master key. The people having one of the slot keys may not be supposed to know the master key (because then you could not lock somebody out without reencrypting all the data).
Thus a new key is given (password or file), turned into a ... | LUKS: find a deleted key(slot) |
1,590,335,475,000 |
I want to change a partition to Ext3 or Ext4 and used fdisk to print the availlable partition types:
19 Linux swap 0657FD6D-A4AB-43C4-84E5-0933C84B4F4F
20 Linux filesystem 0FC63DAF-8483-4772-8E79-3D69D8477DE4
21 Linux server data 3B8F8425-20E0-4F3B-907F-1A25A76F98E8
2... |
Text mode
Let fdisk do it's job on the external drive (if you need to create one or more partitions). Use the default partition type (don't worry about it).
Then use mkfs.ext4 and create an ext4 file system.
Graphical mode
Use gparted and let it create partition(s) and file system(s).
| Which Linux partition type to chose for external USB HDD with EXT3 or EXT4? |
1,590,335,475,000 |
I can not figure out why its not allowing me to put a filesystem on this logical volume, does anyone have a solution or troubleshoot for this?
root@Home-Pi:~# vgs
VG #PV #LV #SN Attr VSize VFree
VG_Remote_Storage 2 1 0 wz--n- 18.19t 0
root@Home-Pi:~# lvs
LV VG ... |
Your raspberry pi is running a 32-bit version of linux, so mkfs.ext4 is formatting the filesystem with 2^32 blocks, which (with a 4k block size) limits the filesystem to a maximum size of 16 TiB. XFS on 32-bit linux is also limited to 16 TiB.
Interestingly, the Raspberry Pi 4 Model B has a Broadcom BCM2711 which is... | mkfs.ext4 not working on 19.1TB logical volume |
1,590,335,475,000 |
I installed Fedora 28. But I resized the partition that contained Fedora (/dev/sda7) wrongly using GParted and now I can't boot my system. (Note the partition format is ext4)
|
Resizing a partition does not implicitly resize any filesystem it might contain. You should have shrunk the filesystem and then shrunk the partition. (I'm surprised gparted didn't warn you.)
However, to try and fix the damage, resize the partition back to whatever it was before. If you're not sure of the value then ma... | ext4 partition is broken during resizing with gparted |
1,590,335,475,000 |
We have a Raspberry Pi located at a location where it may experience frequent power loss. I'm trying to make it scan, and repair (if necessary) a filesystem every time it boots up, in case the power loss causes FS corruption. The filesystem in question is ext4, but it is NOT the root filesystem.
It seems that I can do... |
You don't need to set "-c 1" on the filesystem. That means "force a full e2fsck run each mount", which would both be annoying (slow boot time), and unnecessary for ext4 with a journal. Even without a journal you don't strictly need to run a full e2fsck if the filesystem has been cleanly unmounted (it will record this ... | Does a filesystem check initiated from /etc/fstab auto-repair? |
1,590,335,475,000 |
I need to backup / copy the files of my Linux installation to an external drive, so that I can restore them onto the new, larger disk.
The destination disk for the restoration is twice as large, and will have larger partitions, ext4 and linux-swap. Imaging the entire disk or its first partition is not really a good ... |
Per @cat's comment, posting my comment as an answer -
Have you considered making a sparse file the size of your old installation, formatting it as a ext4 file system, and mounting on loopback, then copying to that? Would solve all the permissions loss, etc. issues. exFAT's filesize limit is 16EiB, surely large enough.... | Backing up Linux to a Windows file system for later restoration |
1,590,335,475,000 |
I like to use dynamically allocated images in VirtualBox.
It is preferred way if you like to distribute you image (remember Vagrant?).
What Linux FS can reclaim unused blocks to VirtualBox when dynamically allocated image is used?
I saw that users run:
sudo dd if=/dev/zero of=/EMPTY bs=1M || : ; rm -f /EMPTY
to shrin... |
Official docs state: https://www.virtualbox.org/manual/ch08.html#vboxmanage-storageattach
VBoxManage storageattach <UUID> --nonrotational:
This switch allows to enable the non-rotational flag for virtual hard disks. Some guests (i.e. Windows 7+) treat such disks like SSDs and don't perform disk fragmentation on such ... | What FS can reclaim unused blocks to VirtualBox when dynamically allocated image is used? |
1,590,335,475,000 |
Basically, the EXT4 filesystem has chunks of data in size of 128MiB (by default), and this chunk is called a "group" or "group of blocks", which basically looks like this on the disk:
The bigger the disk, the more groups you have one after the other.
When you use the dumpe2fs tool, it can simply tell you how many gro... |
Basically it boils down to whether the meta data and/or the data is affected.
Generally speaking, when the meta data is corrupted the affected files/directories become inaccessible (or partially inaccessible). Tools such as fsck may be able to fix the corruption, but it really depends on precisely what has been damage... | What would happen if you zeroed out a certain group of blocks in the EXT4 filesystem? |
1,590,335,475,000 |
I am trying to recover whatever data I can from a bad partition on a hard drive. Unfortunately fsck failed to resolve the issue. The output from mount is as follows:
$ sudo mount /dev/sda3 /mnt/
mount: wrong fs type, bad option, bad superblock on /dev/sda3,
dmesg output is as follows:
[77027.447708] ata1.00: exceptio... |
Use ddrescue insted of dd (it will ignore read errors), then you can run fsck on the dumped image with various -b parameters.
man fsck:
-b superblock
Instead of using the normal superblock, use an alternative
superblock specified by superblock. This option is normally
used ... | Recovering from an AMNR Hard Drive error (ext4) |
1,590,335,475,000 |
What does it mean "Structure needs cleaning" ?
I've never seen such error code before - and man cp is not that helpful.
It has happened to me on ext4.
I was trying to copy directory using:
cp -arv dirname dirname.bak
|
Some googling told me that there was a patch to ext4 last year that mentions returning EUCLEAN upon an out of space error.
E.g. https://patchwork.ozlabs.org/patch/452275/
The fix is either to run e2fsck -E bmap2extent, or to chattr +e the file.
| cp: cannot create directory 'ABC.DEF/G/H': Structure needs cleaning |
1,590,335,475,000 |
I'm using Linux (Ubuntu) and I was told that I can use the method described below to clone the system's hard drive to another one - to plug into a new machine. (Without booting from a Live CD)
It assumes that the system's disk is /dev/sda, the partition mounted as root is /dev/sda1, and an empty disk to clone it to is... |
The best way to do this would be to create an LVM snapshot of the filesystem and then use the snapshot as the source for making the copy. That has two benefits:
it doesn't require rebooting the system when you are done
it flushes and syncs the filesystem so you don't have inconsistent/corrupt metadata
Failing that, ... | Is using the SysRQ Emergency Remount an acceptable way to clone hard disk? |
1,590,335,475,000 |
According to Debian
Ext2/3/4 filesystems are upgradeable to Btrfs; however, upstream recommends backing up the data, creating a pristine btrfs filesystem with wipefs -a and mkfs.btrfs, and restoring from backup -- or replicating the existing data (eg: using tar, cpio, rsync etc).
Because Debian doesn't support BTRFS... |
Other than the liability that something goes wrong you need only
Remove the original filesystem metadata with btrfs subvolume delete
Defrag to make file extents more contiguous with btrfs filesystem defrag
Run btrfs balance
Summary of btrfs convert
| Upgrading from ext3/4 to BTFS vs fresh install? |
1,590,335,475,000 |
I changed my /etc/fstab from:
UUID=f1fc7345-be7a-4c6b-9559-fc6e2d445bfa / ext4 errors=remount-ro 0 1
UUID=4966-E925 /boot/efi vfat umask=0077 0 1
to this:
UUID=f1fc7345-be7a-4c6b-9559-fc6e2d445bfa / ext4 data=jou... |
TTYs have insanely fast keyboard set by default. I tried to log in about 30 times before the final success.
If you have numbers in your password or login name, you may want to turn the numlock on.
Issue this command, but make sure you use your drive and partition number:
sudo mount -o data=ordered,remount,rw /dev/n... | Fstab adding data=journal crashed my Linux' ext4 upon boot, how to fix? |
1,677,841,150,000 |
I am trying to root cause a customer case where 2 Identical drives, formatted with the same command, led to a difference of ~55GB in total disk space due to additional Inode overhead.
I want to understand
The math on how 2xInodes per group translates to 2xInode count
How does Inodes per group get set when lazy_itable... |
I found the difference in these 2 cases was a difference in the e2fsprogs version - 1.42.9 & 1.45.4. I didn't think of checking that and only relied on mke2fs.conf file. Apologies for this obvious miss and thanks @lustreone for suggesting.
I am still curious to know the math relating to Inodes per group and Inode cou... | How does "Inodes per group" and "lazy_itable_init" flag relate to the "Inode count" value in an ext4 filesystem? |
1,677,841,150,000 |
I was wondering how to log flag changes in a file, e.g. chattr +a somefile.
I realized that timestamps shown by stat somefile are not useful to audit flag changes: when the file is appended, it overrides the last time a flag was changed.
|
auditd was created exactly for that. inotify/fsnotify require a ton of code to be useful and they are generally not used for this purpose.
There are plenty of manuals on the net, e.g.
https://www.thegeekdiary.com/how-to-audit-file-access-on-linux/
https://www.xmodulo.com/how-to-monitor-file-access-on-linux.html
| How to log flag changes to files on ext4 and xfs filesystems? |
1,677,841,150,000 |
I have a VPS with CentoS 7 that is robbing me of 68GB of space. My server has 160GB of storage. It says it is using 120GB. But my server should only be using about 50GB - 65Gb.
I found that there is a file in the root that is 68GB with file name of "." when I ran (du -h --max-depth=1) which I thought was the sum total... |
So, the good news is you don't have a big file called '.'. That's just the summary for the current directory.
I'd throw -a into your du flags to see filenames too.
If that doesn't show you anything new you might want to check the output of lsof | grep deleted to see if maybe there's a process running that tried to del... | Unknown usage of HDD Space |
1,677,841,150,000 |
gparted reports 74GB used and 9.02TiB available (seems reasonable).
df reports 40MB used, but only shows 8.6TiB available (suddenly 425 GiB missing)
Disk Info in the file manager reports similar to df, showing 0 bytes used but only 8.6TiB available
Am I actually losing over 5% of my disk to overhead?
|
I found the solution to this over on serverfault - the reserved blocks for root-owned processes by default take 5% of your drive. I lowered this to 0% using tune2fs -m 0 /dev/sdb1 and now I am showing all my free space, as espected.
| Created a new volume on a 10TB (9.1TiB) hard drive, getting conflicting information regarding free space! |
1,677,841,150,000 |
I'm trying to create an update image from an ext4 filesystem which should only consists of the changed files. So basically I have a Debian distro with an ext4 root file system. I want to create a base image A from that and install updates afterwards (e.g. apt upgrade). After the update I want to create another image B... |
I don't think that the "diff image" will work at the filesystem level like you want it to. There are too many variables in the placement of files/directories, metadata checksums (on newer systems), journal blocks, etc. that make it impossible to take a block-level diff from one filesystem and apply it to another file... | Create ext4 img from diff |
1,611,512,903,000 |
I have a 35G mount as my root file system, and until now, it was reporting 1% usage.
I was using an SD card for my storage and today I got a new one. I'm mounting my /swap partition on that, so I decided to partition the new one with a swap and a "normal" one.
First I created an NTFS partition in case I want to use th... |
Turns out during my mounting/umounting/rebooting etc., something happened.
I was mounting the SD card on /media, and I'm not sure why, but when I finished with the SD card setup, apparently the /media was created as a directory and not a mount, so it was that directory taking up space.
I didn't notice that it's not ac... | Root file system reported as being 100% without adding any file |
1,611,512,903,000 |
I have a situation where I observe that BackupPC stalls for a particular host. This host runs Debian 10 (and has e.g. Docker installed).
During that situation, two rsync-related processes are running on that host (parent sudo /usr/bin/rsync --server ... and child /usr/bin/rsync --server ...). When I try to find out wh... |
In the end, this looked related to "orphaned" files apparently stemming from NFS mounts into containers at a time when an NFS server could not be reached. Once I identified and removed those (e4defrag and) lsof were no longer stallingm, i.e. behaved again as expected.
| How can lsof -p $pid be stalling when ls /proc/$pid/fd is not? |
1,611,512,903,000 |
I have an SSD with LVM with one LV dedicated to a Win7 VM .vdi file of 80Gb.
The underlying fs is ext4.
After installing a new SSD and setting up the new LV's in migrating, the copy from the old SSD failed on copy with
Input Output Err No.5
Failed on cp, rsync, dd
And a quick look at
dmesg
[ 5829.294651] sd 2:0:0:... |
I didn't find and answer on U&L but serverfault provided one.
So I will leave their solution here for anyone else. Let me know if there is a dupe in U&L in which case I will take this down.
The solution was as simple as
dd if=Win7.vdi of=~/mnt/Win7.vdi bs=4k conv=noerror,sync
After having checked that the block size... | Recover large file which contains a few bad blocks |
1,611,512,903,000 |
I'd like to set up one external hard drive that would serve as the backup drive for two different laptops, both running Linux. I understand this is problematic b/c each machine will have its own set of user IDs, which can cause permission conflicts/general chaos.
I'm just wondering if there are any solutions I haven't... |
No, it is not a problem. Use a normal Linux filesystem.
I would recommend that you use one directory for one computer backup and an other for the second computer. Create the directory as root, and give the expected owner/group to the directory (or just keep root, if you want to backup all system). So mkdir and chown.... | Shared Hard Drive? |
1,611,512,903,000 |
I have a project which requires a lot of contact with ext file system. But the majority of tools is based on Windows. Thus is there any software or plugin for explorer which allow the access to ext on Windows?
|
Yes one method could be via third party software installed on your Windows computer such as outlined in this post.
However, I cannot vet for the authenticity of any Windows programs or whether they will compromise the integrity of your ext file system.
Another method, if your Windows System and Linux System are inst... | Is there a practical way to view ext file system on Windows? |
1,611,512,903,000 |
I am using an Ubuntu 16.04 LTS. I ran into an unusual problem with my disk usage. Some of my applications were aborted with the message on the terminal stating "not enough disk space available".
The following is the out put of
df -hT
Filesystem Type Size Used Avail Use% Mounted on
udev devtmpfs ... |
It is not only normal for a filesystem to be mounted as /,
it is mandatory.
It is common for the root filesystem to be ext4.
To free the space used in /tmp:
cd /tmp.
ls -la.
Look at the files and see whether any of them are important
(they shouldn’t be),
and try to figure out if they are being used by running proc... | ext4 mounted on / and tmp consuming disk space |
1,611,512,903,000 |
I am getting many of these messages on one of my systems:
[ 348.515157] EXT4-fs (vda9): VFS: Can't find ext4 filesystem
[ 348.517587] EXT4-fs (vda9): VFS: Can't find ext4 filesystem
[ 348.519944] EXT4-fs (vda9): VFS: Can't find ext4 filesystem
[ 348.522487] squashfs: SQUASHFS error: Can't find a SQUASHFS superbloc... |
Those messages are normally generated by mount attempting to guess the filesystem type when mounting. The -t option to specify a filesystem type is optional and if it's not specified, mount will attempt to determine the type automatically.
In your case, something is mounting or attempting to mount vda9 without specify... | "VFS: Can't find ext4 filesystem" on ZFS disk |
1,611,512,903,000 |
I'm trying to extend my root partition with the unallocated space but it seems like the unallocated space didn't exist. When I reinstalled the system I had two different Free Spaces, one with 32GB and other with 19GB but wasn't able to fix them in the same partition.
I've tried with the solutions in other posts with ... |
Seems like you're running gparted from your Linux-distro, and that means that some of you're partitions - including your root-partition - are in use (that's what that icon looking like a numerical keypad or whatever means). You can't move or resize a partition your actually actively using (which you here are).
Try ru... | Can't extend root partition with unallocated space [duplicate] |
1,611,512,903,000 |
Know that my chances are small (if even there are :().
I have a HDD of 500G with 1 logical volume (ext4). By accident I overwrote it with an ISO of 1,5G:
dd if=linuxmint-18-xfce-32bit.iso of=/dev/sdb
Now I lost all data. Is there some way to re-create the logical volume to get some data back? I have the LVM backup fi... |
I did not succeed to restore the partition since it missed the start of it. What I did was recovering most of my data with the tool photorec that is from the same author as testdisk. Before I could use it I had to create a partition that started after the ISO partition until the end of the disk. photorec searched this... | Recover LVM after overwrite with dd |
1,430,793,528,000 |
Is it possible to reduce a mounting lv safely at RHEL6/CentOS6 with ext4 file system? If it is, how can I do that?
|
As per RedHat documentation you can't reduce mounted filesystem. Check here for detailed document
| Lvreduce online on RHEL 6 or centos 6 with ext4 file systems |
1,430,793,528,000 |
I have a Linux partition formatted to ext4 and I accidentally formatted it with Mac OS X Disk Utility to HFS+ (Mac OS X Extended Journaled).
I tried to recover it with http://www.r-studio.com/ on Windows but I can't get any files except few from trash or temporary browser files.
Now I'm trying another software on OS X... |
I don't have any knowledge of the tool you are using, but I used before UFSexplorer and it was good (take a look here)
Now, if you managed with the tool r-studio to get some files that's good, it means that the HFS+ format didn't wipe your disk and prepared it's initial data struture,
So, you can use UFS explorer or t... | Recover Linux ext4 partition formatted to hfs+ |
1,430,793,528,000 |
we have VM machine with disks as sdb sdc sdd ,,, etc
we create ext4 file system on sdb disk as the following
mkfs.ext4 -j -m 0 /dev/sdb -F
mke2fs 1.42.9 (28-Dec-2013)
Discarding device blocks: done
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blo... |
lsblk uses UDev database to get information about filesystems so if it doesn't show the filesystem type, something is probably wrong with UDev. To check what UDev knows about the device, use udevadm info /dev/sdb and look for ID_FS_TYPE key.
It's also possible that UDev is just too slow on your device and the value is... | lsblk + file system type not appears from lsblk |
1,430,793,528,000 |
I'm learning a bit about Ext4 file system here. In the first table on this link they are describing fields of the inode. Each field entry has an:
offset
size
name
description
In the description field the document states some of these values are Lower or Higher bits. What does lower/highter bits mean, and what is the... |
Let's take one example, using the doc that you link to in your question for reference: the i_uid field has size __le16 and is described as Lower 16-bits of Owner UID. If the system which created this filesystem allows 16-bit user IDs only, then all of the user ID can fit into the i_uid field: __le16 does indeed stand ... | What does upper/lower bits mean? |
1,430,793,528,000 |
Is it safe to run tune2fs -l /dev/device on a mounted filesystem? That is, listing the current values (I'm trying to do this to see if the filesystem is marked as clean).
If it's ok, is there a definitive source where this is documented so that I can rest assured I won't corrupt something?
Thanks
|
The dumpe2fs command can be used on a mounted partition.
| Is it safe to run tune2fs -l /dev/device on a mounted filesystem? |
1,430,793,528,000 |
I have a ~450 gigabyte ext4 filesystem, located at /dev/sda5 on my computer. The partition it resided in, however, was about a gigabyte bigger. So I used the command e2image -ra -p -O XXXX to move the filesystem to the left, so I could use the extra gigabyte on a partition at /dev/sda6. I didn't run that exact command... |
I think the commenters are right that your file system is pretty well broken. I once accidentally wrote /dev/zero to my main hard drive (while operating) for about half a second before killing it. I was able to use Photorec (http://www.cgsecurity.org/wiki/PhotoRec) to recover my partition table (pretty much automagi... | Corrupt ext4 filesystem after e2image interrupted |
1,430,793,528,000 |
1] i have installed kali linux on my laptop. but it converted all my hard disk partition into ext4 formate. so my old data on ntfs partition is not showing on ext4 partition. so, how i can get my old data back..
2] andthen i tried to install windows 10 back but it not showing any partition at installation process..
i... |
If you repartition a hard disk drive, all the data on that hard disk drive is gone.
That's why it's always recommended to make a backup of your data before making drastic changes (like changing operating systems) to your computer.
| how i can get ntfs data on ext4 partition? |
1,430,793,528,000 |
I've been using Linux on ext4 file systems for many years - before that I used Windows on NTFS for many years. The ext4 file system strikes me as much more sensitive to crashes than NTFS. If I had a crash on Windows, the NTFS file system was always able to restore operation almost without problems, whereas the ext4 f... |
Both NTFS and ext2/ext4 are damaged by an unclean shutdown.
This is caused by cached metadata, open files, file left open after being deleted, partially written files, and many other issues.
The resilience of the repair process in both has improved dramatically over the last 20 years. It's just that ext4 is very nois... | Why is the ext4 file system so sensitive to crashes? [closed] |
1,326,231,956,000 |
There is often a need in the open source or active developer community to publish large video segments online. (Meet-up videos, campouts, tech talks...) Being that I am a developer and not a videographer I have no desire to fork out the extra scratch on a premium Vimeo account. How then do I take a 12.5 GB (1:20:00) M... |
$ ffmpeg -i source-file.foo -ss 0 -t 600 first-10-min.m4v
$ ffmpeg -i source-file.foo -ss 600 -t 600 second-10-min.m4v
$ ffmpeg -i source-file.foo -ss 1200 -t 600 third-10-min.m4v
...
Wrapping this up into a script to do it in a loop wouldn't be hard.
Beware that if you try to calculate the number of iterations... | How can I use ffmpeg to split MPEG video into 10 minute chunks? |
1,326,231,956,000 |
I found something for videos, which looks like this.
ffmpeg -i * -c:v libx264 -crf 22 -map 0 -segment_time 1 -g 1 -sc_threshold 0 -force_key_frames "expr:gte(t,n_forced*9)" -f segment output%03d.mp4
I tried using that for an audio file, but only the first audio file contained actual audio, the others were silent, oth... |
This worked for me when I tried it on a mp3 file.
$ ffmpeg -i somefile.mp3 -f segment -segment_time 3 -c copy out%03d.mp3
Where -segment_time is the amount of time you want per each file (in seconds).
References
Splitting an audio file into chunks of a specified length
4.22 segment, stream_segment, ssegment - ffmpeg... | How do I split an audio file into multiple? |
1,326,231,956,000 |
I have an FFmpeg command to trim audio:
ffmpeg -ss 01:43:46 -t 00:00:44.30 -i input.mp3 output.mp3
The problem I have with this command is that option -t requires a duration (in seconds) from 01:43:46. I want to trim audio using start/stop times, e.g. between 01:43:46 and 00:01:45.02.
Is this possible?
|
ffmpeg seems to have a new option -to in the documentation:
-to position (input/output)
Stop writing the output or reading the input at position. position
must be a time duration specification, see (ffmpeg-utils)the Time
duration section in the ffmpeg-utils(1) manual.
-to and -t are mutually exclusive and -t ha... | Trim audio file using start and stop times |
1,326,231,956,000 |
I have two video clips. Both are 640x480 and last 10 minutes. One contains background audio, the other one a singing actor. I would like to create a single 10 minute video clip measuring 1280x480 (in other words, I want to place the videos next to each other and play them simultaneously, mixing audio from both clips).... |
ffmpeg \
-i input1.mp4 \
-i input2.mp4 \
-filter_complex '[0:v]pad=iw*2:ih[int];[int][1:v]overlay=W/2:0[vid]' \
-map '[vid]' \
-c:v libx264 \
-crf 23 \
-preset veryfast \
output.mp4
This essentially doubles the size of input1.mp4 by padding the right side with black the same size as the original video... | Merge two video clips into one, placing them next to each other |
1,326,231,956,000 |
What command lines to use to convert from avi to mp4, but without destroying the framesize and making the file small as the original size or a little bit bigger, and same thing with mp4 to avi? Whenever I tried converting it became like 2 gb
|
Depending on how your original file was encoded, it may not be possible to keep the file size.
This command should keep frame sizes and rates intact while making an mp4 file:
ffmpeg -i infile.avi youroutput.mp4
And this command will give you information about your input file - the frame size, codecs used, bitrate, et... | Encode with ffmpeg using avi to mp4 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.