Results 1 to 10 of 13

Thread: Changing program priority through terminal

Hybrid View

  1. #1
    Join Date
    Jul 2007
    Location
    England... UK
    Beans
    374
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Question Changing program priority through terminal

    Hi

    I use rhythembox to play my music - its always jammed and crashed and i've had to force quit - and I think thats to do with all my music being stored on an external.

    But now when I do anything while playing music it goes very shuddery starting and stopping - I keep trying to change the priority through the system monitor and it says 'starting administrator' like it's going to ask me for a password - but then it and the system monitor disappear - and the priority is not changed...

    how do I change rhythembox's priority to very high (-13) roughly - in the terminal?

    also - any insight into why rhythembox always crashes and fails to start would be great - thanks.
    THE OFFICIAL SMILE - smiling once again!

    PHANTOM JOKER

  2. #2
    Join Date
    Feb 2007
    Location
    Edinburgh, Scotland
    Beans
    391

    Re: Changing program priority through terminal

    You can use the 'renice' command to prioritise processes:

    Code:
    renice -<priority> <rhytmbox's pid>
    As to why its crashing/locking. If you are using an old connection (USB 1.1) and playing high bitrate files, it may be a problem that Rhythmbox just cant get to the files quick enough, though I cant see this being a problem with compressed music (MP3, Ogg, AAC), only with lossless (Flac).

    It could also be your drive is spinning down too much, so when you want to play music it has to spin up before you can access it (this can take a while). If rhythmbox is locking on startup, or when you hit play on a new song, this may be your problem. Try waiting a few seconds and see if it resolves itself.

    You could also try a different player (Rhythbox isnt the best player going, IMO). You should try Banshee (sudo apt-get install banshee) and see if you still get the same problems.
    Today we have 15 minutes of fame, tomorrow 15 minutes of anonymity.
    My Blog | Veza - Opensource TinyURL clone with sensible URLs

  3. #3
    Join Date
    Apr 2005
    Location
    Finland/UK
    Beans
    Hidden!
    Distro
    Ubuntu 16.04 Xenial Xerus

    Re: Changing program priority through terminal

    Remember to use "sudo" with renice if you want to increase a programs's priority (decrease the nice). Only root is allowed to set nice levels below 0..

    But I agree with bobbocanfly that your probelms are probably resulting from something else than too low priority..

  4. #4
    Join Date
    Jul 2007
    Location
    England... UK
    Beans
    374
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: Changing program priority through terminal

    is there a way to stop my disk 'spinning down too much'?

    sorry if thats a silly question
    THE OFFICIAL SMILE - smiling once again!

    PHANTOM JOKER

  5. #5
    Join Date
    Jan 2008
    Beans
    4,757

    Re: Changing program priority through terminal

    Code:
    hdparm -B 200 -S 240 -M 254 /dev/sda
    Sets the hard drive up for performance over power savings...
    Should prevent spinning down unless...
    [EDIT]
    20 minutes idle. (Which will probably never happen, with various app fsync()'ing once every 5/10 minutes )


    Regards
    Iain
    Last edited by ibuclaw; August 8th, 2008 at 02:11 PM.

  6. #6
    Join Date
    Jul 2007
    Location
    England... UK
    Beans
    374
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: Changing program priority through terminal

    THANKS - but I dont think my external is dev/sda -- um how do i find out which hard drive is sda and sda1 etc? :S
    THE OFFICIAL SMILE - smiling once again!

    PHANTOM JOKER

  7. #7
    Join Date
    Jan 2007
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: Changing program priority through terminal

    Quote Originally Posted by phantomjoker View Post
    THANKS - but I dont think my external is dev/sda -- um how do i find out which hard drive is sda and sda1 etc? :S
    You can probably determine it with:
    Code:
    df -Th | grep dev
    Sample output:
    Code:
    /dev/sda2     ext3     34G  717M   31G   3% /home
    /dev/sda3     ext3     30G  177M   29G   1% /media/sda3
    /dev/sda5     ext3     29G  6.7G   22G  25% /media/av
    New to Wayland.

    Retired.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •