Hi!I purchased a pendrive recently (the one in the topic name) and the writing speed is horrible in Mint...In Seven / XP it works great , over 7 MB/s while in Mint it starts at 14-15 and goes down to 1.1 MB/s.This morning I copied a movie on it and it went down to 1 MB/s and copied in "bursts" , my lappy became unresponsive for a few seconds , and after copying was finished I gave the drive the unmount command and it said that it is still writing to the device...stayied like that for 2-3 minutes till it said it can be disconnected.
Can this issue be solved ? I do not want to dual-boot for the pendrive...
PS : the pendrive is usb 2.0 and the lappy has 2.0 ports as well.
_____________________
PPS : Filesystem is NTFS because I need the stick to work on Windows systems as well (I also do some freelance software installs ) )
Linux Mint 7 and Kingston 8GB U-Drive -- speed issue
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Linux Mint 7 and Kingston 8GB U-Drive -- speed issue
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Re: Linux Mint 7 and Kingston 8GB U-Drive -- speed issue
I actually just discovered a half-assed fix for this.
It has to do with the kernel I/O Scheduling. As a default, it's set to CFQ - Completely Fair Queuing. There are three other possibilities - Anticipatory, Deadline, and Noop.
For me, Anticipatory is the one that works best, although I haven't really given to much time to Noop.
In any event, with your USB device connected, open a terminal and enter the following command:(assuming your USB drive is mounted to /dev/sdb; if not, change the device in the command accordingly)
This will tell you what kind of I/O Scheduling your device is using. Since, for whatever reason, the Linux Standard® has been CFQ since kernel 2.6.18, it should give you a return like this:
You can then change the type of scheduling by issuing the command:(again, assuming you're device is /dev/sdb.)
I recommend trying each type of scheduling over a period of a day or so before settling on one.
You then have the choice of either compiling a new kernel (yikes!) with that type of scheduling default built in, or - much easier - setting your current kernel to use the type of I/O Scheduling you want.
To do this, open up your menu.lst fileand look for the lines that load your Linux kernel. It should look like this, and the bolded line is the one you're interested in:
The final product should look like this:
Also note that the performance gains you get when defaulting your system using this kernel boot option are not as good as those you get when you compile your own kernel with the option you want built right in. Using myself as an example, the difference between the kernel boot option (20 to 25MB/s) and a compiled kernel (a solid 30MB/s) is between 5 and 10 MB/s.
Post back and let me know how it works for you.
It has to do with the kernel I/O Scheduling. As a default, it's set to CFQ - Completely Fair Queuing. There are three other possibilities - Anticipatory, Deadline, and Noop.
For me, Anticipatory is the one that works best, although I haven't really given to much time to Noop.
In any event, with your USB device connected, open a terminal and enter the following command:
Code: Select all
cat /sys/block/sdb/queue/scheduler
This will tell you what kind of I/O Scheduling your device is using. Since, for whatever reason, the Linux Standard® has been CFQ since kernel 2.6.18, it should give you a return like this:
Code: Select all
noop anticipatory deadline [cfq]
Code: Select all
echo anticipatory > /sys/block/sdb/queue/scheduler
I recommend trying each type of scheduling over a period of a day or so before settling on one.
You then have the choice of either compiling a new kernel (yikes!) with that type of scheduling default built in, or - much easier - setting your current kernel to use the type of I/O Scheduling you want.
To do this, open up your menu.lst file
Code: Select all
sudo gedit /boot/grub/menu.lst
At the end of that line, you'll want to add the option "elevator=as" for anticipatory scheduling, "elevator=deadline" for deadline scheduling, or "elevator=noop" for noop scheduling.title Linux Mint 7 Gloria, kernel 2.6.28-15-generic
root (hd0,7)
kernel /vmlinuz-2.6.28-15-generic root=/dev/sda6 ro quiet splash
initrd /initrd.img-2.6.28-15-generic
quiet
The final product should look like this:
I should note that while your system (as a whole) is defaulted to CFQ scheduling, the performance gains you see under each other type of device scheduling will be a little less than what it would be if your system were defaulted to that scheduling type.title Linux Mint 7 Gloria, kernel 2.6.28-15-generic
root (hd0,7)
kernel /vmlinuz-2.6.28-15-generic root=/dev/sda6 ro quiet splash elevator=as
initrd /initrd.img-2.6.28-15-generic
quiet
Also note that the performance gains you get when defaulting your system using this kernel boot option are not as good as those you get when you compile your own kernel with the option you want built right in. Using myself as an example, the difference between the kernel boot option (20 to 25MB/s) and a compiled kernel (a solid 30MB/s) is between 5 and 10 MB/s.
Post back and let me know how it works for you.
Re: Linux Mint 7 and Kingston 8GB U-Drive -- speed issue
Thanks , but no luck ... I think I am doing something wrong because I get :
with or without sudo before echo...and yes , it is sdb (checked that in the output of dmesg)...
Code: Select all
terror@Aspire5720Z ~ $ cat /sys/block/sdb/queue/scheduler
noop anticipatory deadline [cfq]
terror@Aspire5720Z ~ $ sudo echo anticipatory > /sys/block/sdb/queue/scheduler
bash: /sys/block/sdb/queue/scheduler: Permission denied
Re: Linux Mint 7 and Kingston 8GB U-Drive -- speed issue
Switch right to a root terminal by using 'sudo su'. It'll work then.terrorblader wrote:Thanks , but no luck ... I think I am doing something wrong because I get :with or without sudo before echo...and yes , it is sdb (checked that in the output of dmesg)...Code: Select all
terror@Aspire5720Z ~ $ cat /sys/block/sdb/queue/scheduler noop anticipatory deadline [cfq] terror@Aspire5720Z ~ $ sudo echo anticipatory > /sys/block/sdb/queue/scheduler bash: /sys/block/sdb/queue/scheduler: Permission denied
Re: Linux Mint 7 and Kingston 8GB U-Drive -- speed issue
Yes , it worked,but the problem persists..also , I noticed that the transfer slows down only when it starts showing the actual speed in gnome..till then it is fluent , the moment the actual speed apears in the window the transfer starts to pause and go in short bursts of data ...
PS : I'll put in a CD with Mint and see if the problem persists from the live system as well to check if it could be something related to my install.Will come back with results in a few minutes.
Ok , I am now running from the liveCD ... transfer still goes in bursts of data , but the write speed is over 6 MB/s , closer to the real speed of the drive (it should be 8-10 MB/s according to the manufacturer)..so it seems there is a problem with my install as well...
What I forgot to mention is that I use the 2.6.30 kernel due to intel graphics problems and also because my WLAN works out of the box , no win drivers needed.
So I guess a reinstall is needed ?
PS : I'll put in a CD with Mint and see if the problem persists from the live system as well to check if it could be something related to my install.Will come back with results in a few minutes.
Ok , I am now running from the liveCD ... transfer still goes in bursts of data , but the write speed is over 6 MB/s , closer to the real speed of the drive (it should be 8-10 MB/s according to the manufacturer)..so it seems there is a problem with my install as well...
What I forgot to mention is that I use the 2.6.30 kernel due to intel graphics problems and also because my WLAN works out of the box , no win drivers needed.
So I guess a reinstall is needed ?
Re: Linux Mint 7 and Kingston 8GB U-Drive -- speed issue
Which part worked? Setting the device scheduling, or setting system scheduling in the boot option for grub? Or both?terrorblader wrote:Yes , it worked,but the problem persists..also , I noticed that the transfer slows down only when it starts showing the actual speed in gnome..till then it is fluent , the moment the actual speed apears in the window the transfer starts to pause and go in short bursts of data ...
[...]
What I forgot to mention is that I use the 2.6.30 kernel due to intel graphics problems and also because my WLAN works out of the box , no win drivers needed.
So I guess a reinstall is needed ?
If you've already compiled yourself a kernel to make Intel drivers work better, then you're no stranger to it and I'd recommend making a new one with the proper scheduling built right in.
You can try to reinstall, but you're going to end up starting over from square one, with Intel, with Wireless, and with this.
Stable Kernel version is 2.6.31.4 (IIRC) so you're already a tad out of date with the one you have.
Choice is yours, really.
[SOLVED]Re: Linux Mint 7 and Kingston 8GB U-Drive -- speed i
The speed issue ... it is partly solved ) sorry for using such ambiguous phrases...
So , from the Linux Mint 7 x32 liveCD the write speed is better (6.5-6.6 MB/s) but the bursts are still there.
I did not do any kernel compiling , just entered some new repos in sources.list to get 2.6.30 kernel on my system.
Didn't know about the stable version as being 2.6.31 , last I tested it was rc6 or 7 if I recall correctly and did not work on my system.
I tried kernel compilation once , but resulted in an unbootable system and I do not want to go there unless absolutely necesary.
So .. if I reinstall now I must reapply all the patches , customize my system again and all that .. so thats 2-3 hours of work .. and when Mint 8 is out reinstall again ...
If I do not reinstall I have to live with 1.1 MB/s write speed for at least a month...or set up a Win XP .. but then rebooting is just not me ...
Guess I'll do a reinstall soon ... thanks for the help optimize me!
So , from the Linux Mint 7 x32 liveCD the write speed is better (6.5-6.6 MB/s) but the bursts are still there.
I did not do any kernel compiling , just entered some new repos in sources.list to get 2.6.30 kernel on my system.
Didn't know about the stable version as being 2.6.31 , last I tested it was rc6 or 7 if I recall correctly and did not work on my system.
I tried kernel compilation once , but resulted in an unbootable system and I do not want to go there unless absolutely necesary.
So .. if I reinstall now I must reapply all the patches , customize my system again and all that .. so thats 2-3 hours of work .. and when Mint 8 is out reinstall again ...
If I do not reinstall I have to live with 1.1 MB/s write speed for at least a month...or set up a Win XP .. but then rebooting is just not me ...
Guess I'll do a reinstall soon ... thanks for the help optimize me!