This lab was an introduction to UNIX essentials, and how to navigate the Uni-versitys Linux system.
cp
, takes two arguments, a source file and a destination file. An example command can be cp ~/lab1tutorial/index.html ~/public_html/index.html
. To copy directories, we can use cp -R
(recursive). [1]
chmod
can either take traditional g+rw
configurations, but can also use octal parameters, which is much faster. In permissions, rwxrwxrwx
is broken down into three octal values, being 0 if not allowed and 1 if allowed. Therefore, to change a file's permission to rwx--x--x
one would write chmod 711
, as rwx--x---x
is expressed as 711 in octal. public_html
to work, all directories that need to be accessed must be set to rwx--x--x
and all files that need to be accessed must be set to rwxr--r--
.
I came into this lab with some slight prior knowledge of linux, so the lab wasfairly straightforward to follow. This was just an introduction to UNIX whichintroduced several very useful commands like chmod
.
Prior, I had installed WSL2 and Ubuntu 20.04 onto my system already, andknew about the basics such as copying and moving files, and navigating the filestructure.
In my opinion, chmod
being able to use octal representation was the mostuseful thing I learned, as using one octal number is much quicker than thealternative long form.