Giter Club home page Giter Club logo

operating-system-practicum's Introduction

Operating-system-practicum

Guan ye

第一次作业

9.19

1.安装virtual box和ubuntu 18.04 server

https://www.virtualbox.org/wiki/Downloads

https://www.ubuntu.com/download/server

注意1、进入之后默认以username用户登录,登录后提示符为"$",修改root密码,退出后再使用root登录,提示符为"#",说明是超级用户。

(参考:https://blog.csdn.net/u011990090/article/details/39768585

注意2、Linux中~和/的区别,/是根目录,根目录下有home、root等目录。~是一个代位符,表明是个人目录。如果以root登录,~是/root/;如果以name登录,~是/home/name/

2.在ubuntu**享宿主机的一个目录

遇到问题: 直接输入命令

 mount -t vboxsf share /mnt/serverShare

提示:"wrong fs type,bad option,bad superblock..."

因为没有安装增强插件,在virtual box的“设备”那一项安装时,提示“未能加载虚拟光盘 E:\VirtualBox\VBoxGuestAdditions.iso 到虚拟电脑”

解决办法:https://blog.csdn.net/yaolong336/article/details/78030500

按这个教程做可以实现共享文件夹,应该是已经安装了需要的插件,但是在“设备”那一项的“安装增强插件”依然提示问题,可能是因为使用的是ubuntu server版本

3.在宿主机上用ssh访问到ubuntu

设备-网络-网卡1-网络地址转换(NAT)

端口转发-主机端口22-子系统端口22

在windows的cmd中直接ssh到root无法成功密码登陆

cat /etc/ssh/sshd_config

修改为 PermitRootLogin yes

systemctl

systemctl restart sshd

4.更新国内apt更新源mirriors

先备份

cp /etc/apt/sources.list /etc/apt/sources.list.backup

修改文件

vim /etc/apt/sources.list

更新生效

sudo apt-get update

5.构建开发环境hello world.c编译运行

sudo apt-get install gcc
vim helloworld.c
gcc helloworld.c -o helloworld
./helloworld

6.安装taglist,在vim中呈现函数列表

下载taglist_46.zip在windows的共享文件夹中

解压,将文件复制到对应文件夹

sudo cp /mnt/serverShare/taglist_46/doc/taglist.txt /usr/share/vim/vim80/doc/
sudo cp /mnt/serverShare/taglist_46/plugin/taglist.vim /usr/share/vim/vim80/plugin/

改动vim配置文件

sudo vim /etc/vim/vimrc

最后加入如下内容

"""taglist设置"""
let Tlist_Auto_Open = 1
let Tlist_Ctags_Cmd = '/usr/bin/ctags'
let Tlist_Show_One_File = 1
let Tlist_Exit_OnlyWindow = 1

operating-system-practicum's People

Contributors

fengwz17 avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.