9

Would it be possible to install packages without admin rights(sudo?) on Ubuntu?

It doesn't have to be system-wide, maybe a private installation within /home.

I want this because I'd like to setup my PC so that you can do anything you need without ever having to enter the escalate your privileges. This way, I can blissfully allow anyone to use my Ubuntu system (on their own account of course) and simply telling them that whenever they are told to authenticate, DONT.

Currently, I can run Banshee, chromium, LO, save data on /home,manage my music library etc without authentication.

However, I cannot install say, VLC or CHM reader without privileges.

I understand that there are some packages that touch the inner workings of my system(e.g linux-kernel-image) where it won't make sense to have a private "/home" installation. And that packages are not neatly labeled "trivial" & "non-trivial".

Nonetheless I would like the system(synaptic?) to try and install without any rights until it cannot proceed, upon which it displays the traditional "You require authentication"

Lekensteyn
  • 174,277

3 Answers3

1

You should manually unpack the deb, place files somewhere and ensure it has access to the libs it need. Chroot command may help to use dpkg or apt-get, though I don't think many people did it. If you want to make a machine, where you don't need root passwd at all, you should use sudo extensively. Sudo can be tuned to allow only given commands with given parameters passwordless.

  • The part I have issue with is not having to need root passwd. It is having to have escalated privileges even briefly! Using sudo extensively might make my system more vulnerable. Still, thx for the advice – user16570 May 08 '11 at 21:51
0

I would not advise doing it but you can do it by installing from source code I have found. ie you have to download the source code and build it yourself. However you would have to have all the build essential tools installed first.

Then when you download the source code you could create an apps dir in your home directory and build from source in there.

In general: ./configure --prefix=/home/user/apps make make install

Then add /home/user/apps/bin to your path in your bashrc.

Again I cannot advise this. Why don't you set up a guest user account on your pc or have them logged in as other users or even better get them to use a live pen drive version of Unity 11.04 with a persistent file system and they can boot off of that and install what they want there. Saves messing your pc up.

andybleaden
  • 1,903
  • This in itself is good advice! I actually use this technique when I do not have appropriate privileges. However, I cannot expect my mum to install this way... btw Why do you advise against this? Is it about the technique you've described or about what I want conceptually? I am aware of a) guest user options and b)pen drive options but AFAIK a) cannot install new packages and b) has suboptimal performance. thx for the advice though – user16570 May 08 '11 at 21:54
  • If you create a live pen drive using the usb creater app you can make a persistent file on it so that you can add applications etc later...gives it a bit of memory – andybleaden May 09 '11 at 14:36
0

Use a virtual machine. That will solve all of your problems:

  • Each user can have their own VM which they have root access to.
  • Since the VM is completely isolated from the host, you don't have to worry about anything getting messed up on host.
  • Most virtualization programs do not require root privileges to launch a VM.
Nathan Osman
  • 32,155