Skip to content

An awesome & curated list of anything that might be useful for computer science students

License

Notifications You must be signed in to change notification settings

AgentDS/Awesome-Mess

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Awesome-Mess

Awesome

An awesome & curated list of anything that I find might be useful for computer science students. Kinda messy but try to organize it well.

Some blogs are in Chinese, and some in English. Hope this repo will be helpful for more people.

ENJOY IT!!

日常碰到的收集的觉得可能对计算机相关专业学生有用的资料。可能有点乱,会不定期整理。

有些链接文章是中文的,有些是英文的。希望尽可能对更多人有用。

[toc]

Open-source Related 开源开发相关

Linux Server 服务器使用

服务器使用

  • 如何用SSHFS?让服务器文件系统挂到自己本地系统里方便文件传输

    1. 下载osxfuse

      brew install --cask osxfuse
    2. 下载sshfs

      brew install sshfs
    3. 设置文件目录挂载

      # 创建本地目录,用于挂载
      $ mkdir -p xxxx/mount_remote
      
      # 挂在远程目录到本地,输入密码即可,若要免密,创建sshkey即可
      $ sshfs xxxx@x.x.x.x:/home/yyy /xxxx/mount_remote -p port_num
      
      # 在macOS的Finder里像用本地正常文件夹一样打开远程目录,进行操作
      
      # 使用结束,取消挂载(有时候会自动断掉链接,就不用手动取消挂载了)
      $ umount /xxxx/mount_remote
  • 使用expect完成脚本一键登录服务器(README.md中的Tips on Using SFTP & SSH)

  • nvidia-smi查看GPU的使用信息并分析

  • 通过SSH远程使用jupyter notebook

  • 服务器公私钥登陆

    1. 在本地计算机的~/.ssh目录下生成密钥对:

      # in local dir ~/.ssh
      $ ssh-keygen  <== 建立密钥对
      Enter file in which to save the key (~/.ssh/id_rsa): sample  <== 自定义名字
      Enter passphrase (empty for no passphrase):  <== 按 Enter
      Enter same passphrase again:  <== 按 Enter
      Your identification has been saved in sample.  <== 私钥
      Your public key has been saved in sample.pub.  <== 公钥
      The key fingerprint is:
      SHA256:xxxxxxxxxxxxxxx/xxxxx xxxxxx.local
    2. 在remote服务器上确定存在~/.ssh目录,如果没有,创建并改变权限:

      # in remote dir ~
      $ mkdir .ssh
      $ chmod 700 ~/.ssh
    3. 在remote服务器上确定存在~/.ssh/authorized_keys文件,如果没有,创建并改变权限

      # in remote dir ~
      $ cd .ssh
      # in remote dir ~/.ssh
      $ touch authorized_keys
      $ chmod 600 authorized_keys
    4. 把本地生成的公钥文件~/.ssh/sample.pub发送到remote服务器的~/.ssh目录下:

      # in local dir ~/.ssh
      $ scp sample.pub [remote user name]@[remote address]:./.ssh/
    5. 在remote服务器的~/.ssh/authorized_keys中加入~/.ssh/sample.pub的内容:

      # in remote dir ~/.ssh
      $ cat sample.pub >> authorized_keys
    6. 在本地的~/.ssh/config文件中加入remote服务器的配置:

      Host serverA
          user [用户名]
          hostname [服务器ip]
          port [端口号]
          identityfile ~/.ssh/sample
    7. 在本地命令行输入以下命令直接登陆:

      $ ssh serverA
  • 直接kill掉名字中包含xxxx字符的所有进程:

    ps aux | grep -i xxxx | awk '{print $2}' | xargs kill -9

Docker

Coding & Experiments 代码 & 实验

Paper Writing 论文写作

Personal Page 个人网页

About

An awesome & curated list of anything that might be useful for computer science students

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published