Loading ...
Sorry, an error occurred while loading the content.

Re: sudo problem

Expand Messages
  • james_jolin
    ... Thanks for the tip. The change of owner on the mozilla folder did the trick. I had tried that on firefox itself, but that did not work. Thanks again. JIm
    Message 1 of 10 , Mar 16, 2009
    • 0 Attachment
      --- In LINUX_Newbies@yahoogroups.com, Donald Cooley <dfcooley@...> wrote:
      >
      > On Mon, Mar 16, 2009 at 11:32:42PM -0000, james_jolin wrote:
      > > That would appear to be the case...root(sudo) owns firefox. I ran firefox from the menu and got the same result.
      > > Jim
      > >
      > >
      >
      > Hi Jim,
      > It looks like someone was having a similar problem and found a solution.
      > I googled and found this here,
      > <http://www.techsupportforum.com/alternative-computing/linux-support/142916-k-ubuntu-firefox-only-runs-sudo.html>,
      > which might help you:
      >
      >
      > "... Then I found out that the .mozilla folder that had firefox in it had its
      > permissions set root-root, so I did chown on it and changed it to my
      > regular username, and it works now :)"
      >
      > Let us know if you need help with the 'chown' command.
      > I think the following should work for you:
      >
      > sudo chown yourUserName -R .mozilla
      >
      > Hope that helps.
      >
      > --
      > Regards,
      > Donald Cooley
      > Registered Linux user 444909
      >
      Thanks for the tip. The change of owner on the mozilla folder did the trick. I had tried that on firefox itself, but that did not work.
      Thanks again.
      JIm
    • Donald Cooley
      ... Hi Jim, Glad it s working for you. -- Regards, Donald Cooley Registered Linux user 444909
      Message 2 of 10 , Mar 16, 2009
      • 0 Attachment
        On Tue, Mar 17, 2009 at 02:17:57AM -0000, james_jolin wrote:
        > >
        > Thanks for the tip. The change of owner on the mozilla folder did the trick. I had tried that on firefox itself, but that did not work.
        > Thanks again.
        > JIm
        Hi Jim,
        Glad it's working for you.

        --
        Regards,
        Donald Cooley
        Registered Linux user 444909
      • Loyal Barber
        ... root normally owns firefox. Root owns firefox on every system I own so I don t think that is the problem. Look and see who owns the .mozilla folder and
        Message 3 of 10 , Mar 17, 2009
        • 0 Attachment
          --- In LINUX_Newbies@yahoogroups.com, "james_jolin" <jjolin@...> wrote:
          >
          > --- In LINUX_Newbies@yahoogroups.com, Donald Cooley <dfcooley@> wrote:
          > >
          > > On Mon, Mar 16, 2009 at 10:07:54PM -0000, james_jolin wrote:
          > > > Hope you all can help with this one...I've run out of ideas. For reasons I wont go into, I ran firefox under sudo and now when I run it from the icon in the task bar I get a firefox with no home page, no history just a bare. blank page. To get the original firefox I have to run it as sudo firefox. How can I change things back to the way they were.
          > > > Jim
          > > >
          > > >
          > > >
          > > I'm wondering if you are still the 'owner' of firefox or if sudo/root
          > > is. What happens if you run firefox from the menu instead of the icon in
          > > the task bar?
          > > Regards,
          > > Donald Cooley
          > > Registered Linux user 444909
          > >
          > That would appear to be the case...root(sudo) owns firefox. I ran firefox from the menu and got the same result.
          > Jim
          >

          root normally owns firefox. Root owns firefox on every system I own
          so I don't think that is the problem. Look and see who owns the
          .mozilla folder and subsequent files/dirs under this. You can find
          the .mozilla folder in your home directory which is usually something
          like /home/user where "user" is your login id.


          $ ls -la |grep mozilla
          drwx------ 4 myuser myuser 4096 2009-02-03 22:54 .mozilla
          drwx------ 3 myuser myuser 4096 2009-02-03 22:54 .mozilla-thunderbird
        • Jeff Lane
          ... Thanks for sharing that... that s interesting... Even more interesting, and I know the OP said for reasons I won t go into but to be honest, I am
          Message 4 of 10 , Mar 17, 2009
          • 0 Attachment
            On Mon, Mar 16, 2009 at 9:25 PM, Donald Cooley <dfcooley@...> wrote:

            > "... Then I found out that the .mozilla folder that had firefox in it had
            > its
            > permissions set root-root, so I did chown on it and changed it to my
            > regular username, and it works now :)"

            Thanks for sharing that... that's interesting...

            Even more interesting, and I know the OP said "for reasons I won't go
            into" but to be honest, I am genuinely curious why someone would run a
            web browser using sudo...

            But back on topic for a moment, I'd not have thought that running it
            with sudo would have changed user/group ownership in the user's home
            directory. I've never noticed sudo doing that before.

            So as a quick test, I ran a simple script that gets user input and
            then echos the input back to console using sudo and nothing changed.

            Then I added tee to it to see what happens:
            and sure enough the output file was owned by root.root. Not sure why
            it ever occurred to me that that would happen, but it did and that's
            pretty neat.

            One final test, I ran the script as a normal user, using tee to create
            an output file, THEN reran it using sudo (always using tee -a to keep
            the original file)

            This time, when I ran the first iteration, the output.txt file was
            owned by my normal user, then after re-running the script w/ sudo, the
            output file remained owned by my normal user, presumably because root
            has access to everything.

            Interesting way to kill a few minutes at work, so thanks!
          • Scott
            ... Errm, because of idiotic design by various distros. Let me try to remember why did I have to do it on Fedora---oh yeahhhh..... Firefox wants to add 10,000
            Message 5 of 10 , Mar 17, 2009
            • 0 Attachment
              On Tue, Mar 17, 2009 at 11:24:21AM -0400, Jeff Lane wrote:
              > On Mon, Mar 16, 2009 at 9:25 PM, Donald Cooley <dfcooley@...> wrote:
              >
              > > "... Then I found out that the .mozilla folder that had firefox in it had
              > > its
              > > permissions set root-root, so I did chown on it and changed it to my
              > > regular username, and it works now :)"
              >
              > Thanks for sharing that... that's interesting...
              >
              > Even more interesting, and I know the OP said "for reasons I won't go
              > into" but to be honest, I am genuinely curious why someone would run a
              > web browser using sudo...

              Errm, because of idiotic design by various distros. Let me try to
              remember why did I have to do it on Fedora---oh yeahhhh.....

              Firefox wants to add 10,000 language extensions, and I only need English
              and Japanese. So, I could disable them, but then it would check
              again--I'd uncheck check for extensions on startup but it would do it
              again after an upgrade.

              So, after a little googling, it turns out that only root can uninstall
              these stupid extensions--no offense to anyone who needs the language,
              but I really don't need Basque. So, I had to start it with sudo.
              (However, I didn't have the OP's issue after that.)

              When the desktop distributions give their users some credit (perhaps, I
              admit, undeserved) for a brain, and take off training wheels, then there
              may be no need for such things. As long as they go with the "You're too
              stupid to be root," thing, there will always be some unusual need that
              they don't forsee.

              >
              > But back on topic for a moment, I'd not have thought that running it
              > with sudo would have changed user/group ownership in the user's home
              > directory. I've never noticed sudo doing that before.

              See above, it didn't for me either--I wonder if this was one of those FF
              installs where the OP ran it from an untarred file in their $HOME
              directory? I know there was a bug for awhile where after installation,
              $HOME/.mozilla would be root owned.

              >
              >
              > One final test, I ran the script as a normal user, using tee to create
              > an output file, THEN reran it using sudo (always using tee -a to keep
              > the original file)
              >
              > This time, when I ran the first iteration, the output.txt file was
              > owned by my normal user, then after re-running the script w/ sudo, the
              > output file remained owned by my normal user, presumably because root
              > has access to everything.
              >
              > Interesting way to kill a few minutes at work, so thanks!

              You're still at work?

              Go to sleep.

              Oh yeah, I forgot--you young guys don't sleep, and don't even THINK of
              telling me you're getting old you young whippersnapper.


              --
              Scott Robbins
              PGP keyID EB3467D6
              ( 1B48 077D 66F6 9DB0 FDC2 A409 FA54 EB34 67D6 )
              gpg --keyserver pgp.mit.edu --recv-keys EB3467D6

              Buffy: It's weird, though. In this way, I feel like he's still
              watching me.
              Willow: Well, in a way he sort of is...in the way of that he's right
              over there.
            • Donald Cooley
              ... Can t say I m familiar with how to use the tee command. -- Regards, Donald Cooley Registered Linux user 444909
              Message 6 of 10 , Mar 17, 2009
              • 0 Attachment
                On Tue, Mar 17, 2009 at 11:24:21AM -0400, Jeff Lane wrote:
                > On Mon, Mar 16, 2009 at 9:25 PM, Donald Cooley <dfcooley@...> wrote:
                >
                > > "... Then I found out that the .mozilla folder that had firefox in it had
                > > its
                > > permissions set root-root, so I did chown on it and changed it to my
                > > regular username, and it works now :)"
                >
                > Thanks for sharing that... that's interesting...
                >
                > Even more interesting, and I know the OP said "for reasons I won't go
                > into" but to be honest, I am genuinely curious why someone would run a
                > web browser using sudo...
                >
                > But back on topic for a moment, I'd not have thought that running it
                > with sudo would have changed user/group ownership in the user's home
                > directory. I've never noticed sudo doing that before.
                >
                > So as a quick test, I ran a simple script that gets user input and
                > then echos the input back to console using sudo and nothing changed.
                >
                > Then I added tee to it to see what happens:
                > and sure enough the output file was owned by root.root. Not sure why
                > it ever occurred to me that that would happen, but it did and that's
                > pretty neat.
                >
                > One final test, I ran the script as a normal user, using tee to create
                > an output file, THEN reran it using sudo (always using tee -a to keep
                > the original file)
                >
                > This time, when I ran the first iteration, the output.txt file was
                > owned by my normal user, then after re-running the script w/ sudo, the
                > output file remained owned by my normal user, presumably because root
                > has access to everything.
                >
                > Interesting way to kill a few minutes at work, so thanks!

                Can't say I'm familiar with how to use the tee command.
                --
                Regards,
                Donald Cooley
                Registered Linux user 444909
              Your message has been successfully submitted and would be delivered to recipients shortly.