Course Content#
Introduction to the Course#
What is Linux#
-
Linux Development: Unix → Mac → Windows → Linux
-
Typical Linux Distributions: Ubuntu, RHEL (Red Hat Enterprise Linux), CentOS (Red Hat's guinea pig), Suse
-
PS: deepin is based on Debian
- What is it? Why use it?
Basic Linux Usage#
- How to use: Learning methods, common patterns
- How to look up: man pages, tldr-Github (open-source, concise)
man + [command to look up]
- File and directory operations, system information retrieval, software configuration, system optimization
- ⭐Using Linux for programming, development, and server deployment
Common Commands#
- 50+
Delete the database and run away: rm -rf /*
Shell Programming#
- What is a script, analogous to a movie script
- Essential difference from C programs: C deals with data, while Shell combines many processes together
- Compared to the scripting language Python, Shell is a built-in interface in Linux, directly connected and callable
- Mastering: Variables, input/output, branching, looping, ⭐arrays
Introduction to Operating Systems#
What is an Operating System#
-
The interface between users and computers, and between computer hardware and other software, like a butler
-
Linux System: The kernel is the abbreviation for all operating systems based on Linux
-
-
Overall architecture
- Hardware level (visible and tangible)
- Kernel level (file subsystem, process control subsystem, etc.)
- User level (C language library, etc.)
-
History of Linux#
【Operating Systems】
- 1941: The first computer was created
- 1965: Multics, a comprehensive system, developed by several large companies' laboratories
- 1969: Unics, created by Ken Thompson (originated from Multics for gaming purposes)
- 1973: C language, rewritten Unix by Dennis Ritchie
- 1984: Minix, created by Tanenbaum
- 1991: Linux, Git, ⭐created by Linus Torvalds (for gaming purposes, during his third year of college)
- Tanenbaum and Torvalds still interact frequently
- Size of the Linux kernel code: 100,000 lines (1993) 👉 27.8 million lines (2020)
- Design principle of Linux: Satisfy a portion of users, different systems have different user preferences [open-source]
- Linux/Unix's share in the domestic server operating system market: 86%, 2016
- Windows servers are commonly used in state-owned enterprises and public institutions, with code and systems that may have been patched together decades ago, as long as they are stable, they dare not make changes
[Hardware Development]
- Vacuum tube era 1950s
- Transistor era 1960s
- Small and medium-scale integrated circuits 1960s, 70s
- Large-scale and very large-scale integrated circuits 1970s to present
[Languages]
- C → C++ → Python → Java → Go
- Python surprisingly predates Java
Why Learn Linux#
- Not necessarily taught in college, but a bonus point
- Study the Linux kernel source code, learn thinking from the experts [data structures, design patterns]
- Rich command ecosystem in Linux, more efficient than Windows
- For example, batch processing files, analyzing data, Windows may require writing scripts or finding software
- Current mainstream computer positions and technologies are based on Linux
The Feud between Windows and Mac#
[Windows] Microsoft#
- Background: Gates' mother was an executive at IBM. Microsoft's DOS system was bundled with IBM-PC, but the launch of this system involved deception
- Highlights: Excel surpassed Lotus, IE defeated Netscape, released the most failed Vista, acquired GitHub
[Mac] Apple#
- Background: Steve Jobs
- Highlights: Jobs was ousted and then returned, iMac, iPod, iPhone, market value surpassed Microsoft in 10 years, brand premium comes from quality
Connection#
- Inspiration comes from Alto developed by Xerox Corporation - with a hard drive, display, graphical user interface, Ethernet, etc.
- Jobs discovered Alto first, asked Gates for help in developing Macintosh, while Gates was also developing Windows
- In 1984, Macintosh was released and became popular worldwide; in 1985, Windows 1.0 was released, which was very similar to Macintosh, and Jobs accused Gates of copying Apple's things
- The feud began
Additional Knowledge Points#
- Uses of cloud servers: building blogs, image hosting, writing services, etc.
- Knowledge of databases is necessary: MySQL 必知必会.pdf, Redis key-value storage database [Redis Command Reference]
Points for Consideration#
Tips#
- 【Recommended Books】
- 鸟哥的 Linux 私房菜 (The Bird's Linux Private Kitchen) → verbose but detailed, suitable for beginners
- ⭐apue [UNIX 高级编程] (Advanced Programming in the UNIX Environment) extraction code: df8j → suitable for non-beginners
- Avoid negative self-suggestions: Can I do it?
- Traits of a good student: loves tinkering, perseveres...
- The invention of routers came from university professors who couldn't communicate with each other due to being in different schools, see The Most Miserable Founder: Although He Invented the Router, He Missed Out on Billions of Dollars Due to Lack of Funding
- The purpose of operations development and test development is to eliminate operations and testing
- Operations belong to sunset positions👈with the popularity of cloud servers, there are people to maintain them