让你的树莓派通过mac下finder访问

作者: shaneZhang 分类: 互联网技术 发布时间: 2015-11-01 11:33

支持afp协议

sudo apt-get install netatalk
sudo apt-get install avahi-daemon
sudo update-rc.d avahi-daemon defaults

创建配置文件

sudo vim /etc/avahi/services/afpd.service
<?xml version="1.0" standalone='no'?>

<!--*-nxml-*-->

<service-group>
   <name replace-wildcards="yes">%h</name>
   <service>
      <type>_afpovertcp._tcp</type>
      <port>548</port>
   </service>
</service-group>
重启服务
sudo /etc/init.d/avahi-daemon restart

安装vnc

sudo apt-get install tightvncserver 
vncserver
cd /etc/init.d
sudo vim tightvncserver
#!/bin/bash
# /etc/init.d/tightvncserver
#

# Carry out specific functions when asked to by the system
case "$1" in
start)
    su pi -c '/usr/bin/vncserver -geometry 1440x900'
    echo "Starting VNC server "
    ;;
stop)
    pkill vncserver
    echo "VNC Server has been stopped (didn't double check though)"
    ;;
*)
    echo "Usage: /etc/init.d/blah {start|stop}"
    exit 1
    ;;
esac

exit 0

配置vnc

sudo chmod +x tightvncserver
sudo pkill Xtightvnc
ps aux | grep vnc
sudo /etc/init.d/tightvncserver start
cd /etc/init.d
sudo update-rc.d tightvncserver defaults

Bonjour协议

sudo vim /etc/avahi/services/rfb.service
<?xml version="1.0" standalone='no'?>

<service-group>
  <name replace-wildcards="yes">%h</name>
  <service>
    <type>_rfb._tcp</type>
    <port>5901</port>
  </service>
</service-group>

sudo /etc/init.d/avahi-daemon restart

原文链接

本页面支持繁体中文友好显示:让你的树莓派通过mac下finder访问

如果觉得我的文章对您有用,请随意打赏。如果有其他问题请联系博主QQ(909491009)或者下方留言!

发表评论

电子邮件地址不会被公开。 必填项已用*标注