1. Install SSH service
安装 openssh-server
sudo apt-get install openssh-server
Start the SSH service
/etc/init.d/ssh start
Check whether the startup is successful
ps -e | grep sshd
Login configuration instructions
sudo vi /etc/ssh/sshd_config
PermitRootLogin prohibit-password is changed to "PermitRootLogin yes
PasswordAuthentication yes //Enable password authentication
PermitEmptyPasswords yes //Enable empty password login encryption mode
Restart the SSH service
/etc/init.d/ssh restart
Problem record
a. buildroot ssh login is not available
Delete the key file
rm /etc/ssh/ssh_host*
sync
b.密钥不对
Add correct host key in /home/zsq/.ssh/known_hosts to get rid of this message.
Offending RSA key in /home/zsq/.ssh/known_hosts:1
rm -rf /home/zsq/.ssh/known_hosts
2. Install Samba
The biggest function of Samba is that it can be used to share folders between Linux and windows systems. To build an SMB service, you must first ensure that windows and ubuntu network interoperability
Download and install samba
sudo apt-get install samba
Create a shared folder in the home directory
mkdir samba
chmod 777 samba
cd samba
touch topeet
Modify the configuration file
vim /etc/samba/smb.conf
and add the following content
[samba]
comment = smbshare home directory
path = /home/samba/ #Enter your own path
valid users = topeet #username
create mask = 0777
directory mask = 0777
force user = topeet #current ubuntu user name
force group = topeet #group where the current user name
is available = yes
unix charset = UTF-8
dos charset = cp936
Set user password
smbpasswd -a topeet
Restart the service
service smbd restart
Enter ubuntu's IP
\192.168.1.16 in the windows running window
to display the shared folder
3. Install nfs service
Download and install
sudo apt-get install nfs-kernel-server
error
E: Unable to acquire lock /var/lib/dpkg/lock-frontend - open (11: resource temporarily unavailable)
E: Unable to acquire dpkg frontend lock (/var/lib /dpkg/lock-frontend), is there another process using it?
sudo rm -r -f /var/lib/dpkg/lock-frontend
Add /home/zsq *(rw, nohide, insecure, async, no_root_squash, no_subtree_check) at the end of the directory
sudo gedit /etc/exports
Restart the service
sudo service nfs-kernel-server restart
Mount on the development board
mount -t nfs -o nolock,ver=3 192.168.12.172:/home/zsq /mnt/nfs
4. Virtual machine settings shared folder
Set up a shared folder in the virtual machine settings. When no mount point is set, the default mount point is /mnt/hgfs