-   Linux - General (
-   -   Folder Max Size and Limiting SSH access to home folder. (

Mefistofeles 11-24-2005 09:41 AM

Folder Max Size and Limiting SSH access to home folder.
Hey guys. I have this situation.
This guy game up to me and wanted to rent a spot in my server to but up a IRC Server.

I have myself ran multiple irc servers etc. So i know what he will be doing. But the problem is, i just dont trust this guy enoth to let him loose in the system files to.

So my questions are.
* How can i limit his SSH access to his Home directory only.
* How can i limit the amount of disk space he can use. (We also wanted me to give him some webspace)

Hope i expressed myself clearly enough. :)

ioerror 11-25-2005 12:10 PM

It's very difficult to restrict someone to their home directory. You could use a crippled shell, but they could just run a command which spawns a new shell....

You can use quotas to limit a users disk space, though I've never used quotas so I don't know how to set it up.

One solution to your problem would be to use user-mode-linux and let him have his own virtual box. You wouldn't need to restrict him to anything since he's locked into the virtual box and his diskspace is limited to the (fixed) size of the filesystem image. You'd need to disable mounting the hostfs though.

Mefistofeles 11-26-2005 12:21 PM

Hmm.. user-mode-linux, you mean this ?

In that case i would have to reinstall linux. I wonder have i got enoth free parts to put together another box for it. :scratch:

Anyways.. I'll try the quotas as soon i get back from my vacation. I'll let you know how it goes.

Tnx mate. :)

ioerror 11-26-2005 12:42 PM


Hmm.. user-mode-linux, you mean this ?
Yup, that's the one.


In that case i would have to reinstall linux.
You don't have to reinstall anything. UML is a virtual machine that runs as a regular process on your host box. Just compile the kernel and grab a filesystem image. In fact, you can run as many as you want (memory permitting) so you could have dozens of virtual machines all networked together via a virtual network and using the host as a gateway.

Mefistofeles 11-26-2005 02:09 PM

ohh.. Great. I'll try it as soon as i get back.

All times are GMT -5. The time now is 08:05 AM.