Page 2 of 2 FirstFirst 12
Results 11 to 14 of 14

Thread: chown command

  1. #11
    Join Date
    Nov 2019
    Beans
    11

    Re: chown command

    This is very helpful. Thanks

  2. #12
    Join Date
    Nov 2019
    Beans
    11

    Re: chown command

    Thanks for the info. Not sure why my book says it can be done. Maybe other distros allow this. I am thinking this capability would bypass the useradd command.

  3. #13
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    19,318
    Distro
    Ubuntu Mate 16.04 Xenial Xerus

    Re: chown command

    Quote Originally Posted by skybird182 View Post
    Thanks for the info. Not sure why my book says it can be done. Maybe other distros allow this. I am thinking this capability would bypass the useradd command.
    There was a history of slightly different commands between the different Unixen, because each company wrote their own. There's a reason the GNU guys think we shouldn't call Linux anything except "GNU/Linux", that's because they are all using the GNU versions of user-land tools. So, pretty much regardless of the Linux distro, the ls command is from GNU and behaves the same way, unless some other specific default feature is enabled which doesn't allow that.

    99.99% of the time, Linux is Linux, except when we use specific system admin commands that are distro specific. For example, Ubuntu has AppArmor, but RHEL uses SELinux instead. So the commands for apparmor are specific to Ubuntu (and child distros) and the commands for SELinux are specific to RHEL (and child distros for it). There is a graphic on Wikipedia that shows the relationships between many (200+?) Linux distros. Most normal people have no idea about that.

    So ... what does all this mean? Basically, chmod is chmod on any Linux distro if the same version of the command is being used on both distros. Check the version for most commands, but using a --version option. Commands do change over time.
    Code:
    $ chmod --version
    Sometimes the option is -v or -V. Always remember that Unix is case sensitive. -v also gets used to add "verbosity" to the output of some commands. More "v"s gets more verbose output which can help troubleshoot problems. That is mostly used by client/server commands, like ssh. ssh -vvvv userid@remote would produce 4 levels of verbosity. Sometimes very handy.

    I remember when the -h option became available for du, df, and sort commands. Completely changed my world. I'll leave that for you to look up and understand. Some commands seem to never change, er ... until they do.

    Other commands seem to change for the worse.
    ifconfig and route make nice output, but have been replaced with ip {option} which makes ugly output. Nice output that is easy to read should be the default. Ugly output, good for scripting, should require an option. IMHO.

    Get a better book. I'd be suspect of other things in that book, since the publisher didn't round up a sufficient review and editorial staff to catch a mistake.

    Or you misread/misunderstood the book. Realistically, that's probably more likely.

  4. #14
    Join Date
    Mar 2007
    Location
    Denver, CO
    Beans
    7,838
    Distro
    Ubuntu Mate 16.04 Xenial Xerus

Page 2 of 2 FirstFirst 12

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •