I'm writing some tests of file ownership, which obviously are pointless if the system isn't a multi-user system. Is there a best way to determine if the system my thing is running on is in fact a multi-user system?
Thanks!
-Pileofrogs
Update: Thanks for your responses! I'll try to clarify my question:
- This is actually more of an academic question than a practical question.
- I'd like to avoid checking a great big list of OSs.
- For this question, I'm defining multi-user as any environment in which the
idea of file ownership is valid. So, maybe a more precise way of asking my question is, is there a 'best' way to determine if the system supports the idea of file ownership.
Another Update: Oh, and you can have Os's with multiple file systems, some of which do and some of which do not support the idea of file ownership.... Ugh...
I think I'd really like a command or set of commands that will succeed in on a system that supports the idea of file ownership and fail on a system that does not.
Yet Another Update: When I say, I'd like to avoid checking a big list of operating systems, I mean I'd like this to work on an OS I've never heard of. I'd like it to work on an OS that doesn't exist yet.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.