LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-03-2002, 11:00 AM   #31
Bill Krauss
LQ Newbie
 
Registered: Mar 2002
Posts: 13

Rep: Reputation: 0

parted seems to have the ability to resize a fat32 partition, i wonder what shrinking/regrowing would accomplish ;-\

-- OR --

Rather than attempting to understand fat32 well enough to write a defragger, I wonder if it could be done like this:

1. Modify the Linux fat32 driver so that it has the option of allocating file space near the high cyls, rather than near cyl 0 as someone mentioned it does. Look at the code snippet from fat_add_cluster() pasted below. Could it be as easy as changing the loop to run from high to low?

2. Mount the filesystem with the "high-alloc" option enabled, and one-by-one copy each file and remove the old one. This process should empty all the low cylinders.

3. Remount the filesystem with the "high-alloc" disabled, and repeat the copy process. As the files move back to the low cylinders, there are no existing files to get in their way, so they are allocated contiguously.

nr = limit; /* to keep GCC happy */
for (count = 0; count < limit; count++) {
nr = ((count + MSDOS_SB(sb)->prev_free) % limit) + 2;
if (fat_access(sb, nr, -1) == 0)
break;
}
 
Old 12-03-2002, 11:04 AM   #32
Bert
Senior Member
 
Registered: Jul 2001
Location: 406292E 290755N
Distribution: GNU/Linux Slackware 8.1, Redhat 8.0, LFS 4.0
Posts: 1,004

Rep: Reputation: 46
You write the app, we'll test it.
 
Old 12-03-2002, 11:40 AM   #33
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Quote:
Originally posted by Bert
Today's random thought for the day:

"A word to the wise: a credentials dicksize war is usually a bad idea on the net."
(David Parsons in c.o.l.development.system, about coding in C.)
Heh ...

Insulting people when proved wrong has always worked? :}

Cheers,
Tink
 
Old 12-03-2002, 12:14 PM   #34
Bert
Senior Member
 
Registered: Jul 2001
Location: 406292E 290755N
Distribution: GNU/Linux Slackware 8.1, Redhat 8.0, LFS 4.0
Posts: 1,004

Rep: Reputation: 46
Quote:
Originally posted by Bert
"A word to the wise: a credentials dicksize war is usually a bad idea on the net."
(David Parsons in c.o.l.development.system, about coding in C.)
Sorry Tinkster, that quote wasn't for you.
 
Old 12-03-2002, 01:39 PM   #35
MasterC
LQ Guru
 
Registered: Mar 2002
Location: Salt Lake City, UT - USA
Distribution: Gentoo ; LFS ; Kubuntu ; CentOS ; Raspbian
Posts: 12,613

Rep: Reputation: 69
Cool a war on filesystem fragging

Cool
 
Old 12-03-2002, 02:40 PM   #36
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Quote:
Originally posted by Bert
Sorry Tinkster, that quote wasn't for you. ;)
I might not be wise, but you're still wrong ;)


Cheers, anyway :)
Tink
 
Old 12-03-2002, 05:27 PM   #37
Bert
Senior Member
 
Registered: Jul 2001
Location: 406292E 290755N
Distribution: GNU/Linux Slackware 8.1, Redhat 8.0, LFS 4.0
Posts: 1,004

Rep: Reputation: 46
"a credentials dicksize war is usually a bad idea on the net."

Bert

Last edited by Bert; 12-03-2002 at 05:29 PM.
 
Old 12-03-2002, 08:05 PM   #38
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
:}

Now you got me really curious!

How does the fact that ext2 doesn't have
a variable size for allocation units relate
to the size of a dick?

Cheers,
Tink

Last edited by Tinkster; 12-03-2002 at 08:08 PM.
 
Old 12-11-2002, 03:15 PM   #39
Nik
LQ Newbie
 
Registered: Nov 2002
Location: pula@yahoo.com
Distribution: Paass
Posts: 16

Rep: Reputation: 0
/sbin/fsck hda1

will defragment your drive
 
Old 12-11-2002, 06:00 PM   #40
aze
Member
 
Registered: Dec 2002
Location: Brazil
Posts: 31

Rep: Reputation: 15
Hi !
Let me make a newbie question: there's a defrag tool for ext3?
 
Old 12-11-2002, 06:19 PM   #41
Thymox
Senior Member
 
Registered: Apr 2001
Location: Plymouth, England.
Distribution: Mostly Debian based systems
Posts: 4,368

Rep: Reputation: 64
Ext3 doesn't need defragging because it doesn't fragment in the first place.
 
Old 12-11-2002, 06:28 PM   #42
crashmeister
Senior Member
 
Registered: Feb 2002
Distribution: t2 - trying to anyway
Posts: 2,541

Rep: Reputation: 47
Ext3 does fragment and there is a defragging tool,too.It's called defrag.But you better check it out good - I am not sure if it also works with ext3.It's originally for ext2.
 
Old 12-11-2002, 06:40 PM   #43
Thymox
Senior Member
 
Registered: Apr 2001
Location: Plymouth, England.
Distribution: Mostly Debian based systems
Posts: 4,368

Rep: Reputation: 64
Yeah, ext3 frags to such a small extent, however, that it is not really worth mentioning. You could reduce the amount of fragmenting by reducing the block-size, but that trades off the amount of space you'll have to store files. Swings and roundabouts. For all intents and purposes, ext3 does not fragment.
 
Old 12-11-2002, 07:18 PM   #44
crashmeister
Senior Member
 
Registered: Feb 2002
Distribution: t2 - trying to anyway
Posts: 2,541

Rep: Reputation: 47
There is some info about this at http://www.rbi.informatik.uni-frankf...ides/reiserfs/
But the link doesn't work.Which leads to the question:How do you delete a post?

Last edited by crashmeister; 12-11-2002 at 07:26 PM.
 
Old 12-11-2002, 07:25 PM   #45
Thymox
Senior Member
 
Registered: Apr 2001
Location: Plymouth, England.
Distribution: Mostly Debian based systems
Posts: 4,368

Rep: Reputation: 64
404ing that, buddy. Would be good to read, though. Sound interesting.
 
  


Reply



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
Defragment Dovid Linux - Software 4 04-26-2005 01:46 PM
should i be concerned (defragment?)... marsques Slackware 6 01-13-2005 12:10 AM
defragment linux glock19 Linux - General 11 09-14-2004 06:22 PM
Looking for defragment software. sjia Linux - Software 8 02-22-2004 10:51 PM
Defragment Anmar Linux - Hardware 2 09-09-2003 11:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:20 PM.

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