Sponsored Content
Special Forums Hardware Filesystems, Disks and Memory Why we don't need to defrag UNIX FS? Post 302451143 by Corona688 on Sunday 5th of September 2010 11:21:32 PM
Old 09-06-2010
Quote:
Originally Posted by amro1
We DO need from time to time to defrag UNIX related filesystem. The problem is that unlike NTFS (which is VERY GOOD, well designed, originated in absolutely terrific OpenVMS, file system)
MS must have made an absolute hash of it, then because, as I've said, I've seen it fragment terribly on drives only 50% full. It certainly doesn't seem to make any effort to obey your ideal of squashing everything at the head of the drive, either.
Quote:
However, if you on single drive PC with Linux on it and do something that makes a lot of small files, then removes them and then do it over again, your system will be fragmented as a hell.
I use a distro that keeps 1.9 gigs of metadata in a tree of 100,000 tiny files with frequent replacement. I've seen ReiserFS fragment badly on that(the files didn't fragment, but the directories themselves did, leading to very slow ls), but not the more common Linux filesystems.
Quote:
By doing that, the restored files fill into the drive one by another, no gaps and no interleaving.
You've got an odd idea of fragmentation. It doesn't mean "all files in one giant clump at the start of the drive", which is a recipe for fragmentation -- growing files will have no room to expand, and get scattered in pieces when they do.

And there's certainly better alternatives to dumping the entire filesystem, like shake.
This User Gave Thanks to Corona688 For This Post:
 

8 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

defrag

is there a command to degragment or clean the disk drives on an HP SCO Unix maching? (6 Replies)
Discussion started by: rnpeters
6 Replies

2. UNIX for Dummies Questions & Answers

I want to cheaply build my own Linux/Unix PC, but don't know where to start

I want to cheaply build my own PC that will run the latest versions of Linspire, Fedora Core, FreeBSD and Solaris, but I don't know where to start. This PC doesn't have to be particulary fast. It's video performance need not be top notch, however, sound quality and sound performance must rock!... (4 Replies)
Discussion started by: Mr. Nice Guy
4 Replies

3. UNIX for Dummies Questions & Answers

which unix?? <donīt know where to post>

Iīm struggling to find a system I like and thatīs not to overwhelming.. Iīve been using Ubuntu/Linux and itīs allright except that itīs pretty buggy and boots extremely slow. Iīm in need of a system that offers good programming features, simple or no x server, fast to boot and STABLE. Donīt care... (2 Replies)
Discussion started by: riwaTNT
2 Replies

4. UNIX for Dummies Questions & Answers

I don't want to go to jail. so I want to start using unix

I use Mac OSX and have been given all of my video editing software... illegally. I don't want to use it anymore and heard that Unix was the way to go. So that is why I am here. What video editing software is out there for Unix. I think I have Unix. Do I? I am sorry and if all anyone can... (0 Replies)
Discussion started by: moz1979
0 Replies

5. Programming

Why I don't have CC1 in my Unix?

gcc works find in my Unix. But when I want to use cc1, system reports: "bash: cc1: command not found". Any clue? Thank you! (2 Replies)
Discussion started by: meili100
2 Replies

6. Shell Programming and Scripting

don't know how to implentment as unix sh script

for each file if file name like xx* for each line in a file if substring(3,6) found in another txt file output to file-a( filename = orginal file + _a) else output to file-b( filename = orginal file + _a) end Next Line (4 Replies)
Discussion started by: ttivanwan@yahoo
4 Replies

7. UNIX for Advanced & Expert Users

don't understand the unix script

if {"$my_ext_type" = MAIN]; then cd $v_sc_dir Filex.SH $v_so_dir\/$v_fr_file Can somebody tell me what does this suggest. I am pretty new to unix and I am getting confused. What i understood from here is If we have a file extension name as MAIN which we have then we change the directory to... (1 Reply)
Discussion started by: pochaman
1 Replies

8. UNIX for Dummies Questions & Answers

Change unix permission when I don't own the file

Hi, A file is transferred from a Windows server(say username : user1) to Unix server via ftp. In unix, the permission of the file for a user, say user2 will be "-rw-r-----". Since the user1 is the owner of the file, user2 is not able to change the file permission using chmod. Is there... (5 Replies)
Discussion started by: merin
5 Replies
E4DEFRAG(8)						      System Manager's Manual						       E4DEFRAG(8)

NAME
e4defrag - online defragmenter for ext4 filesystem SYNOPSIS
e4defrag [ -c ] [ -v ] target ... DESCRIPTION
e4defrag reduces fragmentation of extent based file. The file targeted by e4defrag is created on ext4 filesystem made with "-O extent" option (see mke2fs(8)). The targeted file gets more contiguous blocks and improves the file access speed. target is a regular file, a directory, or a device that is mounted as ext4 filesystem. If target is a directory, e4defrag reduces fragmen- tation of all files in it. If target is a device, e4defrag gets the mount point of it and reduces fragmentation of all files in this mount point. OPTIONS
-c Get a current fragmentation count and an ideal fragmentation count, and calculate fragmentation score based on them. By seeing this score, we can determine whether we should execute e4defrag to target. When used with -v option, the current fragmentation count and the ideal fragmentation count are printed for each file. Also this option outputs the average data size in one extent. If you see it, you'll find the file has ideal extents or not. Note that the maximum extent size is 131072KB in ext4 filesystem (if block size is 4KB). If this option is specified, target is never defragmented. -v Print error messages and the fragmentation count before and after defrag for each file. NOTES
e4defrag does not support swap file, files in lost+found directory, and files allocated in indirect blocks. When target is a device or a mount point, e4defrag doesn't defragment files in mount point of other device. Non-privileged users can execute e4defrag to their own file, but the score is not printed if -c option is specified. Therefore, it is desirable to be executed by root user. AUTHOR
Written by Akira Fujita <a-fujita@rs.jp.nec.com> and Takashi Sato <t-sato@yk.jp.nec.com>. SEE ALSO
mke2fs(8), mount(8). e4defrag version 2.0 May 2009 E4DEFRAG(8)
All times are GMT -4. The time now is 01:10 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy