Comment on page
Let us have the first try on using Linux. Although Linux has a GUI(Graphical User Interface) as Windows and macOS, the server always disable it due to the heavy resource load by GUI. So you have to ensure yourself familiar with the Command Line Operation.
Tips: Although you can use my Linux Server now, I strongly advise you try to install it in your own Laptop. Since you can enjoy the configuration of your own Computer System.
For students at Macao Polytechnic Institute Interest Group, you are welcome to use my server before you have installed one on your computer. Here is a tip on how to open the CLI(Command Line Interface).
Using Spotlight Search (⌘ + Space). Open
Terminal.appand you can see an interactive Interface with a rectangle cursor.
Right-click Start Button, open
CMD. 如果你在使用 Windows 中文版，则是
Since you have already opened your Terminal Software, try to type
sshin the interactive line. And you will get something like this.
usage: ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bind_interface]
[-b bind_address] [-c cipher_spec] [-D [bind_address:]port]
[-E log_file] [-e escape_char] [-F configfile] [-I pkcs11]
[-i identity_file] [-J [user@]host[:port]] [-L address]
[-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p port]
[-Q query_option] [-R address] [-S ctl_path] [-W host:port]
[-w local_tun[:remote_tun]] destination [command]
After having a brief read of the instruction, you should be clear that if the command
sshis installed on your computer (If you are using Windows 10 or 11, any versions of macOS, you should have this command by the OS)
Then we shall use it to log in to my Linux Server.
And you will get this, just type the password I gave you, but you will not see what characters you have typed due to the security.
Then you will get this output:
Welcome to Ubuntu 20.04.3 LTS (GNU/Linux 5.4.0-92-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of WW MM hh:mm:ss YYYY PM CST
System load: 0.07 Processes: 138
Usage of /: 18.1% of 78.69GB Users logged in: 0
Memory usage: 19% IPv4 address for docker0: 172.17.0.1
Swap usage: 0% IPv4 address for eth0: 10.0.12.13
Last login: WW MM hh:mm:ss YYYY from XXX.XXX.XXX.XXX
Welcome to fish, the friendly interactive shell
Type `help` for instructions on how to use fish
ubuntu on VM-12-13-ubuntu at ~ via pythonv3.9.7
This is the welcome message by Ubuntu. And now, you are manipulating my Server rather than your computer via the Internet connection. You can play around with my Server freely without malicious intention. So do not do some stupid kinds of stuff like deleting my file system.
Now let's try to type some commands. What you type is after the -> Symbol. So in the following example, the command is only
lsand what you can see from the shell after you type
hello.txtwhich is the output of the shell.
shell vs terminal
hello.txtis a file that is located at the entry directory when you
sshinto my Server. To see what it contains, the very simple way is
cat(means to concatenate the file content in the output)
-> cat hello.txt
Hello Everyone, Welcome to my Interest Group on `LINUX AND PYTHON AI TOOLKITS`
You can see this file's content by typing `cat hello.txt` command.
->as a mouse pointer, it is the command line prompt. Use
pwdto see where you are.
Now let us create your own folders with your name (change
steve-yanto your name)
-> mkdir steve-yan
And go inside your folder
ubuntu on VM-12-13-ubuntu at ~
-> cd steve-yan
Then you are at
ubuntu on VM-12-13-ubuntu at ~/steve-yan
Actually, we can see it before the
~refers to the
ubuntudirectory. You can think of it as Windows'
👍 Goal: make your own folder at
Linux file system
In Linux, an absolute path is defined as the location of a file or directory relative to the root directory and is designated by a forward slash ( / ). The root directory refers to the top directory that comprises the filesystem containing a series of sub-directories which leads to further sub-directories. On the contrary, a relative path refers to the location of a file or directory relative to the current working directory rather than the root directory. For example,
In the first example, the path starts from the / directory which is the root directory which makes it an absolute pathname. We removed the forward slash / in the second example which makes it a relative pathname meaning it relates to the current working directory instead of the root directory.
Try to type
This will send you to the home directory
/home/ubuntu/, now typing
lsto show the file under this directory. What you will find?
That is because a Linux computer can serve many users at the same time. In fact, this scenario is not appropriate. That is, you are all acting as the user
ubuntunow, for ease of use, I do not let you create your own user in my Server, but it is available in Linux, many users can manipulate the computer at the same time.
👍 Goal: Try to use these commands and tell the usagecd ..cd ~tree ~curl cip.cccurl wttr.inscreenfetchhtop