About this list Date view Thread view Subject view Author view Attachment view

From: Herbert Poetzl (herbert_at_13thfloor.at)
Date: Thu 26 Jun 2003 - 15:29:25 BST


On Tue, Jun 24, 2003 at 09:56:58PM +0300, Alex Lyashkov wrote:
> On Tuesday 24 June 2003 21:17, Chris Murton wrote:
> > vserver-1:/# hostname host-28
> > hostname: you must be root to change the host name
> > vserver-1:/# whoami
> > root
> >
> > Any thoughts? ;)
> >
> Any original vserver have this bug.
> I fix it in snapshot rh-vserver-1052304359.diff.gz (7 may).

hrm, this is _not_ a bug ...

you change the hostname by specifying S_HOSTNAME=<name>
in the /etc/vservers/<name>.conf file ...

best,
Herbert

> For fix you must change one lines in kernel/sys.c.
> From
> asmlinkage long sys_sethostname(char *name, int len)
> {
> int errno;
> char *nodename;
>
> if( (!capable(CAP_SYS_ADMIN)))
> return -EPERM;
> To
> asmlinkage long sys_sethostname(char *name, int len)
> {
> int errno;
> char *nodename;
>
> if( (!capable(CAP_SYS_ADMIN)) && ! is_vps_admin())
> return -EPERM;
>
> Also need fix sys_setdomainname.
>
> --
> With best regards,
> Alex


About this list Date view Thread view Subject view Author view Attachment view
[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Thu 26 Jun 2003 - 16:06:05 BST by hypermail 2.1.3