Hot answers tagged

102

By default, ext2 and its successors reserve 5% of the filesystem for use by the root user. This reduces fragmentation, and makes it less likely that the administrator or any root-owned daemons will be left with no space to work in. These reserved blocks prevent programs not running as root from filling your disk. Whether these considerations justify the ...


76

DiskInternals Linux Reader This program plays the role of a bridge between your Windows and Ext2/Ext3/Ext4, HFS and ReiserFS file systems. Linux Reader Website Features Integrated with Windows Explorer Reader for Ext2/3/4, ReiserFS, Reiser4, HFS, HFS+, FAT, exFAT, NTFS, ReFS, UFS2 Can create and open disk images Freeware


35

As others have already pointed out, it is safe to read from the source disk, or use the target disk outside out the target directory, while rsync is running. It is also safe to read within the target directory, especially if the target directory is being populated exclusively by the rsync run. What's not generally safe is to write within the source ...


31

There is now another solution: Paragon ExtFS for Windows, which acts as a file system driver and so you don't need to use a specialized program to access your files. From the website: Fast and easy read/write access to Ext2 / Ext3 / Ext4 under Windows The only solution with Ext4 read - write support! Easy-to-install and supports Windows 8 / 7 / ...


23

Paragon software offers ExtFS for Windows 2.0 for free for personal use. It allows to read and write ext2 ext3 and ext4 from all Windows OS http://www.paragon-software.com/home/extfs-windows/ It appears to be somewhat similar to Linux Reader from Diskinternals, that can mount all ext, HFS and ReiserFS too, but read-only. http://www.diskinternals.com/linux-...


23

In order to 'force' ext4lazyinit to finish the thing it does with maximum priority, you need to mount the filesystem with 'init_itable=0'. By default it is 10 (for detail please see link below) Alternative solution is to disable the ext4lazyinit thread by mount option 'noinit_itable' which may however not be a good idea on production system (for detail ...


22

This depends of the backup system you use, but in general it is a bad idea to modify the contents of a device while you're backing it up. However, you can read its contents; that's a safe operation, even if it will slow down the process. In your case, rsync will build up a file list and then start the backup. Therefore any file you add to the source HDD ...


21

WSL2 on Windows 10 Build 20211 Windows allows now to mount physical disks using the Windows Subsystem for Linux 2 (WSL). For people who are not familiar with WSL2: ... Windows Subsystem for Linux is a compatibility layer for running Linux binary executables natively on Windows 10 and Windows Server 2019. In May 2019, WSL 2 was announced, introducing ...


16

Not a fundamental speed-up but at least something :) find . -printf \\n | wc -l You really do not need to pass the list of file names, just the newlines suffice. This variant is about 15 % faster on my Ubuntu 12.04.3 when the directories are cached in RAM. In addition this variant will work correctly with file names containing newlines. Interestingly this ...


16

The standard recommended solution is straight-forward: find . -type d -exec chmod 0755 "{}" \+ find . -type f -exec chmod 0644 "{}" \+ This will append as many filenames as possible as arguments to a single command, up to the system's maximum command line length. If the line exceeds this length, the command will be called multiple times. If you want to ...


15

It is safe to read data from the source areas while rsync is operating, but if you update anything the copy that rsync creates/updates is likely to be inconsistent: If you update a file that rsync has already scanned then it will not see the update until a future run. If you update a file it has yet to scan the change will be respected in the destination. ...


11

Source HDD can read anything while rsync. Source HDD can write any content not related to the rsync content. Destination HDD can read anything while rsync. Destination HDD can write anything while rsync with the condition to have sufficient space reserved for the sync'ed content. Of course, in any of the cases, there will be performance reduction.


10

I benchmarked sitaram's answer, Peter Cordes's comment, Fanatique's answer, and harrymc's answer, but this answer has the fastest way. Averages: Deltik's answer* – 7.480 seconds * Credit to Peter Cordes for suggesting parallelism sitaram's answer – 12.962 seconds (73.275% slower than best) Peter Cordes's comment – 14.414 seconds (92.685% slower than best) ...


9

There are two factors that may be interacting. Unlike Windows you can delete files that are open. If you delete a movie that is being streamed, it will be removed from the directory, but will still exist as a file until the streaming program closes it. Once the streaming software closes it, the space will be released. The fuser -m command can be used to ...


8

Most modern OSes now include the CHUI version of parted 3.2 which has resizepart instead: (parted) resizepart 2 100% You should find it in your package manager.


7

1. FreeFileSync GUI tool (Windows, Mac, Linux) To ensure you don't miss any data, I highly highly recommend using a good file-copy tool like FreeFileSync. It is graphical, no cost, free and open source, and cross-platform (Windows, Mac, Linux). Just be sure not to screw it up and copy backwards, deleting everything! That's not hard to get right, however, ...


6

Your disks are fine and are being recognized fine. Your partitions aren't being recognized because the sector sizes are incompatible. The maximum disk size supported by standard 512-byte sectors on an MBR drive is 2TB. In order to allow larger drives, many USB adapters (such as yours) use proprietary 512 => 4096 byte sector translations and pretend to have ...


6

To combine both answers: check if the parent directory webapps has the i or a attributes set by lsattr | grep webapps Then, remove them via chattr -i -a webapps


6

The smaller the block size (1024 bytes, p.e.), the better for efficient disk usage, in case there's a lot of small files on that partition. Try to reformat that partition with the smallest block size: mkfs.ext4 -b 1024 /dev/your_partition


5

If you only need to read from it you can use EXT$ Unpacker, which is free and opensource. http://sourceforge.net/projects/androidicsjbext/


5

You should be able to simply use sudo mount -o remount,rw /


5

Do you want to be able to recover? Or how corrupt are we talking? I would use dd, a block transfer utility. dd if=/dev/urandom of=/dev/sdWV count=X bs=Y seek=Z where sdWV is the device you wish to corrupt sdW will be the block device V will be the partition number X is the number of bocks you want to write Y is the size of each block Z is the place ...


5

I'm not an expert on ext4 but like most file systems it allocates space for files in blocks. The default block size for ext4 is 4096 bytes, so each of your one byte files actually uses 4096 bytes on disk. 19 million times 4096 gives you about your 80GB. If you are just using the files as markers you may be able to use files which are 0 bytes long, in that ...


5

I solved it as follows: I uninstalled all 3rd party software like Ext2Fsd, ext2explore, etc. I cleaned the registry, restarted and paragon extfs is now working. It's copying files to Linux HDD at 100mb/s.


5

Another point which has not been talked about yet is the number of inodes you reserve on your file system. Per default, mkfs creates a number of inodes which should make it possible to put a whole lot of very small files into your file system. If you know that the files will be very big and you will only put a small number of files on the FS, you can reduce ...


4

It turns out the ubuntu build has some problems. Building from source helps: apt-get remove extundelete apt-get install build-essentials e2fslibs-dev tar -xjf extundelete-VERSION.tar.bz2 cd extundelete ./configure make src/extundelete --restore-all image.raw


4

This is what is happening: Initially rsync will build the list of files. Building this list is really slow, due to an initial sorting of the file list. This can be avoided by using ls -f -1 and combining it with xargs for building the set of files that rsync will use, or either redirecting output to a file with the file list. Passing this list to rsync ...


4

It's possible to restore a QCOW2 image created using e2image -Q using e2image -r. For example: # e2image -Q /dev/sdb1 image.qcow2 # e2image -r image.qcow2 /dev/sdb2 Note that I tested this with version 1.42.12 of e2fsprogs. As of >= 1.42.9, e2image also supports the -a flag which allows you to include filesystem data in addition to metadata: # ...


4

I have written ffcnt for exactly that purpose. It retrieves the physical offset of directories themselves with the fiemap ioctl and then scheduling the directory traversal in multiple sequential passes to reduce random access. Whether you actually get a speedup compared to find | wc depends on several factors: filesystem type: filesystems such as ext4 ...


Only top voted, non community-wiki answers of a minimum length are eligible