About 50 results
Open links in new tab
  1. Understanding UNIX permissions and file types

    Feb 10, 2015 · I’ll answer your questions in three parts: file types, permissions, and use cases for the various forms of chmod. File types The first character in ls -l output represents the file type; …

  2. How to copy a file from a remote server to a local machine?

    Mar 5, 2015 · In my terminal shell, I ssh'ed into a remote server, and I cd to the directory I want. Now in this directory, there is a file called table that I want to copy to my local machine …

  3. Most efficient method to empty the contents of a file

    I am aware of three methods to delete all entries from a file. They are >filename touch filename 1 filename < /dev/null Of these three I abuse >filename the most as that requires the least …

  4. How can I display the contents of a text file on the command line?

    Oct 11, 2016 · I would like to display the contents of a text file on the command line. The file only contains 5-6 characters. Is there an easy way to do this?

  5. How to find a file from any directory - Unix & Linux Stack Exchange

    May 1, 2017 · Remember however that Unix permissions apply: if the file is in a directory for which the user running the find command has no access (execute) right, find will not be able to …

  6. sed - How to insert text after a certain string in a file? - Unix ...

    This can also be achieved using the ed utility. It's easier to use sed but nice to be familiar with an additional utility (I came to this page, specifically looking how to achieve this using ed; I …

  7. filesystems - What is a Superblock, Inode, Dentry and a File? - Unix ...

    An inode contains essentially information about ownership (user, group), access mode (read, write, execute permissions), file type, and the data blocks with the file's content. A dentry is the …

  8. How to list processes locking file? - Unix & Linux Stack Exchange

    Using flock, several processes can have a shared lock at the same time, or be waiting to acquire a write lock. How do I get a list of these processes? That is, for a given file X, ideally to find ...

  9. shell - How can I get the size of a file in a bash script? - Unix ...

    Jul 13, 2011 · How can I get the size of a file in a bash script? How do I assign this to a bash variable so I can use it later?

  10. Linux Bash Shell Script Error: cannot execute: required file not found

    Oct 21, 2022 · If you are editing scripts on Windows, you can probably do this by configuring the Windows text editor to create Unix text files, but you may also use the dos2unix utility, …