Difference between revisions of "Template:FriendlyWrt19/zh"

From FriendlyELEC WiKi
Jump to: navigation, search
(编译FriendlyWrt)
(updated by API)
Line 1: Line 1:
==Work with FriendlyWrt==
+
==FriendlyWrt的使用==
===Introduction to FriendlyWrt===
+
===FriendlyWrt简介===
FriendlyWrt is a customized system made by FriendlyElec based on an OpenWrt distribution. It is open source and well suitable for developing IoT applications, NAS applications, smart home gateways etc.<br />
+
FriendlyWrt是友善电子基于OpenWrt定制的系统,完全开源,用于企业物联网二次开发,个人定制NAS,家庭物联网网关等。<br />
  
===Account & Password===
+
===帐户与密码===
By default the password is NULL. You can set a password for root for web and SSH login.
+
默认是空密码,请为root设置一个密码用于web登录与ssh登录。
  
===Network Connection===
+
===连接网络===
Use a network cable to connect {{{1}}}'s WAN to a master router and the board will get an IP address via DHCP. Login into the router and check {{{1}}}'s IP address.
+
用网线连接{{{1}}}的WAN口到你的主路由器,默认将从你的主路由器通过DHCP自动获取IP地址,请登入你的路由器后台查看并记住{{{1}}}的IP地址。
  
===Login FriendlyWrt===
+
===登录FriendlyWrt===
Type {{{1}}}'s IP address in a browser's address bar and enter to open FriendlyWrt's administration page or you can login into FriendlyWrt's administration page via SSH.
+
在电脑浏览器上输入{{{1}}}的IP地址进入FriendlyWrt管理页面,或者通过 ssh 命令登入。
  
===Install Software Packages===
+
===安装软件包===
====Update Package List====
+
====更新可用软件包列表====
Before install software packages update the package list:
+
安装软件前,先更新可用软件包列表:
 
<syntaxhighlight lang="text">
 
<syntaxhighlight lang="text">
 
$ opkg update
 
$ opkg update
 
</syntaxhighlight>
 
</syntaxhighlight>
  
====List Available Packages====
+
====查看可安装的软件包====
 
<syntaxhighlight lang="text">
 
<syntaxhighlight lang="text">
 
$ opkg list
 
$ opkg list
 
</syntaxhighlight>
 
</syntaxhighlight>
At the time of writing there are 3241 available packages.
+
本WiKi编写时,可安装的软件包共有3241个。
  
====List Installed Packages====
+
====查看已安装的软件====
 
<syntaxhighlight lang="text">
 
<syntaxhighlight lang="text">
 
$ opkg list-installed
 
$ opkg list-installed
 
</syntaxhighlight>
 
</syntaxhighlight>
  
====Install Packages====
+
====安装软件====
 
<syntaxhighlight lang="text">
 
<syntaxhighlight lang="text">
$ opkg install <package names>
+
$ opkg install <包各称>
 
</syntaxhighlight>
 
</syntaxhighlight>
  
====Remove Packages====
+
====删除软件====
 
<syntaxhighlight lang="text">
 
<syntaxhighlight lang="text">
$ opkg remove <package names>
+
$ opkg remove <包各称>
 
</syntaxhighlight>
 
</syntaxhighlight>
  
===Work with Docker Applications===
+
===玩转Docker应用===
====Work with Docker: Install JellyBin====
+
====Docker使用:安装JellyBin影音服务器====
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
 
mkdir -p /jellyfin/config
 
mkdir -p /jellyfin/config
Line 47: Line 47:
 
docker run --restart=always -d -p 8096:8096 -v /jellyfin/config:/config -v /jellyfin/videos:/videos jellyfin/jellyfin:10.1.0-arm64 -name myjellyfin
 
docker run --restart=always -d -p 8096:8096 -v /jellyfin/config:/config -v /jellyfin/videos:/videos jellyfin/jellyfin:10.1.0-arm64 -name myjellyfin
 
</syntaxhighlight>
 
</syntaxhighlight>
After installation, visit port 8096 and here is what you would find:<br />
+
安装完成后,使用8096端口进行访问,效果如下:<br />
 
[[File:FriendlyWrt+JerryFin.jpg | frameless|600px|FriendlyWrt+JerryFin]]
 
[[File:FriendlyWrt+JerryFin.jpg | frameless|600px|FriendlyWrt+JerryFin]]
  
====Work with Docker: Install Personal Nextcloud====
+
====Docker使用:安装个人网盘nextcloud====
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
 
mkdir /nextcloud -p
 
mkdir /nextcloud -p
 
docker run -d -p 8888:80  --name nextcloud  -v /nextcloud/:/var/www/html/ --restart=always --privileged=true  arm64v8/nextcloud
 
docker run -d -p 8888:80  --name nextcloud  -v /nextcloud/:/var/www/html/ --restart=always --privileged=true  arm64v8/nextcloud
 
</syntaxhighlight>
 
</syntaxhighlight>
After installtion, visit port 8888.
+
安装完成后,使用8888端口进行访问。
  
===Enable Swap Partition===
+
===启动swap分区===
Run the following commands in a commandline utility and reboot:
+
在命令行执行以下命令,然后重启:
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
 
/etc/enable-swap.sh
 
/etc/enable-swap.sh
Line 64: Line 64:
 
</syntaxhighlight>
 
</syntaxhighlight>
  
===Mount smbfs===
+
===挂载smbfs共享资源===
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
 
mount -t cifs //192.168.1.10/shared /movie -o username=xxx,password=yyy,file_mode=0644
 
mount -t cifs //192.168.1.10/shared /movie -o username=xxx,password=yyy,file_mode=0644
 
</syntaxhighlight>
 
</syntaxhighlight>
  
===Compile FriendlyWrt===
+
===编译FriendlyWrt===
Refer to: [[How to Build FriendlyWrt/zh]]
+
请参考: [[How to Build FriendlyWrt/zh]]

Revision as of 09:48, 10 February 2020

1 FriendlyWrt的使用

1.1 FriendlyWrt简介

FriendlyWrt是友善电子基于OpenWrt定制的系统,完全开源,用于企业物联网二次开发,个人定制NAS,家庭物联网网关等。

1.2 帐户与密码

默认是空密码,请为root设置一个密码用于web登录与ssh登录。

1.3 连接网络

用网线连接{{{1}}}的WAN口到你的主路由器,默认将从你的主路由器通过DHCP自动获取IP地址,请登入你的路由器后台查看并记住{{{1}}}的IP地址。

1.4 登录FriendlyWrt

在电脑浏览器上输入{{{1}}}的IP地址进入FriendlyWrt管理页面,或者通过 ssh 命令登入。

1.5 安装软件包

1.5.1 更新可用软件包列表

安装软件前,先更新可用软件包列表:

$ opkg update

1.5.2 查看可安装的软件包

$ opkg list

本WiKi编写时,可安装的软件包共有3241个。

1.5.3 查看已安装的软件

$ opkg list-installed

1.5.4 安装软件

$ opkg install <包各称>

1.5.5 删除软件

$ opkg remove <包各称>

1.6 玩转Docker应用

1.6.1 Docker使用:安装JellyBin影音服务器

mkdir -p /jellyfin/config
mkdir -p /jellyfin/videos
docker run --restart=always -d -p 8096:8096 -v /jellyfin/config:/config -v /jellyfin/videos:/videos jellyfin/jellyfin:10.1.0-arm64 -name myjellyfin

安装完成后,使用8096端口进行访问,效果如下:
FriendlyWrt+JerryFin

1.6.2 Docker使用:安装个人网盘nextcloud

mkdir /nextcloud -p
docker run -d -p 8888:80  --name nextcloud  -v /nextcloud/:/var/www/html/ --restart=always --privileged=true  arm64v8/nextcloud

安装完成后,使用8888端口进行访问。

1.7 启动swap分区

在命令行执行以下命令,然后重启:

/etc/enable-swap.sh
reboot

1.8 挂载smbfs共享资源

mount -t cifs //192.168.1.10/shared /movie -o username=xxx,password=yyy,file_mode=0644

1.9 编译FriendlyWrt

请参考: How to Build FriendlyWrt/zh