On Wed, Sep 26, 2007 at 10:19:07PM +0100, Peter Tribble wrote:
> On 9/26/07, Nicolas Williams <[EMAIL PROTECTED]> wrote:
> > On Wed, Sep 26, 2007 at 09:52:29PM +0100, Peter Tribble wrote:
> > > Isn't this as easy as changing the format specifier from %8.8s to %8s?
> > >
> > > OK, so then the columns don't line up. How much is this a problem?
> > It's a big problem.
> Bigger than giving completely incorrect output?
Why do you think we limit usernames to 8 characters still? It's because
of things like ps(1) and ls(1) that like to use fixed-width columns.
I second your sentiment: grrr.
> > Personally, I think ps needs an option to output
> > non-column oriented text.
> OK, so I need to work out how wide the column should be
> and expand it to suit?
That might have sufficed once, but I don't know if the silly column
width becomes embedded in stone once it goes out the door. Someone else
can answer that.
> > In the meantime you can use ptree(1) and friends instead of ps(1) and
> > avoid the problem, I think.
> I'm not sure how that helps. The question I wanted ps to give
> me the answer to was simple: show me what processes a user
> is running, and add on which zone they're in so I know which
> zones are in use. Now, 'ps -flZ -u fred' would seem to be the
> ideal command to use, but due to this bug it isn't.
pgrep(1) can give you that.
Note: each zone has its own user/group name/ID namespaces.
> I've just noticed something else. If you have an 8-character username
> it runs into the zone name in the output on S10. On nevada 69, there's
> a space but the headers don't line up. (I'm guessing that a space was
> added after the zonename but that the "ZONE" header didn't get the
> extra space added.)
Now *that* would be a bug.
zones-discuss mailing list