PlugPBX - FreePBX + Asterisk on Debian
需要的硬體:
PlugPBX 預設帳號密碼:
// 下載軟體 win32diskimager
https://launchpad.net/win32-image-writer
開啟軟體,將所下載的 image 寫入到 SDHC。
// 檢查 UBoot version 需 3.4.19 以後,才有支援 SDHC 開機
Windows XP 與 SheevaPlug 用 mini-USB 接上,開啟 PuTTY 並開啟 Console 視窗,SheevaPlug 插上電源開機。
透過 PuTTY 的視窗可以看到開機的狀態,當出現
Hit any key to stop autoboot... <按下任一鍵>
Marvell >>
當看到 Marvell 提示字元時,表示已進入了 UBoot 命令模式,輸入以下指令:
Marvell>> setenv mainlineLinux yes Marvell>> setenv arcNumber 2097 Marvell>> setenv bootargs_console console=ttyS0,115200 Marvell>> setenv bootcmd_mmc 'mmcinit; ext2load mmc 0 0x0800000 /uInitrd; ext2load mmc 0 0x400000 /uImage' Marvell>> setenv bootcmd 'setenv bootargs $(bootargs_console); run bootcmd_mmc; bootm 0x400000 0x0800000' Marvell>> saveenv Marvell>> reset
若一切順利應該會開始啟動 SDHC 的 PlugPBX 系統。
TIPs:
若開機訊息不小心跳過,可以用 root 登入後,執行 reboot 重開機再來一次,或者拿尖物戳 SDHC 槽右側的小孔。
檔案系統
PlugPBX:~# df -h Filesystem Size Used Avail Use% Mounted on /dev/mmcblk0p2 3.4G 854M 2.4G 27% / tmpfs 252M 0 252M 0% /lib/init/rw udev 10M 128K 9.9M 2% /dev tmpfs 252M 0 252M 0% /dev/shm /dev/mmcblk0p1 206M 17M 179M 9% /boot PlugPBX:~# mount /dev/mmcblk0p2 on / type ext2 (rw,errors=remount-ro) tmpfs on /lib/init/rw type tmpfs (rw,nosuid,mode=0755) proc on /proc type proc (rw,noexec,nosuid,nodev) sysfs on /sys type sysfs (rw,noexec,nosuid,nodev) udev on /dev type tmpfs (rw,mode=0755) tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev) devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=620) /dev/mmcblk0p1 on /boot type ext2 (rw)
Linux 版本
PlugPBX:~# uname -a Linux PlugPBX 2.6.30-2-kirkwood #1 Sun Sep 27 22:57:55 UTC 2009 armv5tel GNU/Linux PlugPBX:~# lsb_release -a No LSB modules are available. Distributor ID: Debian Description: Debian GNU/Linux testing (squeeze) Release: testing Codename: squeeze PlugPBX:~# cat /proc/version Linux version 2.6.30-2-kirkwood (Debian 2.6.30-8) (waldi@debian.org) (gcc version 4.3.4 (Debian 4.3.4-3) ) #1 Sun Sep 27 22:57:55 UTC 2009
記憶體狀態
PlugPBX:~# free total used free shared buffers cached Mem: 515888 136552 379336 0 3092 72248 -/+ buffers/cache: 61212 454676 Swap: 224868 0 224868
Asterisk 系統
PlugPBX:~# asterisk -rx "core show version" Asterisk 1.6.1.11 built by root @ debian on a armv5tel running Linux on 2009-12-14 03:19:39 UTC
Web UI
Home
ARI
FOP
FreePBX
phpSysInfo
MUNIN
WEBMIN
// 關閉所有不需要的模組
// 註解所有的模組項目
vi /etc/dahdi/modules
// 關閉 IPV6 功能
echo "blacklist ipv6" >> /etc/modprobe.d/blacklist.conf
檢查 ipv6 呈開啟狀態時
PlugPBX:~# lsmod Module Size Used by dahdi_dummy 3632 0 dahdi 192688 1 dahdi_dummy crc_ccitt 2084 1 dahdi ipv6 284676 31 << 注意這行 loop 15032 0 ext2 63916 2 mbcache 8248 1 ext2 mmc_block 10172 4 ehci_hcd 34648 0 mvsdio 7544 0 mmc_core 55124 2 mmc_block,mvsdio usbcore 137016 2 ehci_hcd mv643xx_eth 26092 0 libphy 22724 1 mv643xx_eth PlugPBX:~# ip a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000 link/ether 00:50:43:1c:12:3a brd ff:ff:ff:ff:ff:ff inet 10.1.1.46/24 brd 10.1.1.255 scope global eth0 inet6 fe80::250:43ff:fe1c:123a/64 scope link << 注意這行 valid_lft forever preferred_lft forever PlugPBX:~# netstat -lt Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State tcp 0 0 *:5038 *:* LISTEN tcp 0 0 localhost:sunrpc *:* LISTEN tcp 0 0 *:webmin *:* LISTEN tcp 0 0 *:cisco-sccp *:* LISTEN tcp 0 0 *:munin *:* LISTEN tcp 0 0 *:ssh *:* LISTEN tcp 0 0 *:smtp *:* LISTEN tcp 0 0 *:4445 *:* LISTEN tcp 0 0 *:36829 *:* LISTEN tcp 0 0 localhost:mysql *:* LISTEN tcp6 0 0 [::]:www [::]:* LISTEN << tcp6 0 0 [::]:ssh [::]:* LISTEN << tcp6 0 0 [::]:microsoft-ds [::]:* LISTEN << tcp6 0 0 [::]:netbios-ssn [::]:* LISTEN <<
// 關閉 Samba 服務
update-rc.d -f samba remove
USB 0: host mode PEX 0: interface detected no Link. Net: egiga0 [PRIME], egiga1 Hit any key to stop autoboot: 0 SDHC found. Card desciption is: Manufacturer: 0x1b, OEM "SM" Product name: "00000", revision 1.0 Serial number: 1909810478 Manufacturing date: 9/2010 CRC: 0x00, b0 = 0 Failed to mount ext2 filesystem... ** Bad ext2 partition or disk - mmc 0:1 ** Failed to mount ext2 filesystem... ** Bad ext2 partition or disk - mmc 0:1 ** ## Booting image at 00800000 ... Bad Magic Number
Ans: 請改用 win32diskimager 將 image 寫入 SDHC,下載連結 https://launchpad.net/win32-image-writer。
Ans: 進入 U-Boot 模式
Marvell>> resetenv Marvell>> reset ... ... Marvell>> setenv mainlineLinux yes Marvell>> setenv arcNumber 2097 Marvell>> setenv bootargs_console console=ttyS0,115200 Marvell>> setenv bootcmd_mmc 'mmcinit; ext2load mmc 0 0x0800000 /uInitrd; ext2load mmc 0 0x400000 /uImage' Marvell>> setenv bootcmd 'setenv bootargs $(bootargs_console); run bootcmd_mmc; bootm 0x400000 0x0800000' Marvell>> saveenv
文件 | 大小 | 日期 | 附件上傳者 | |||
---|---|---|---|---|---|---|
plugpbx-ARI.png PlugPBX - ARI | 19.19 KB | 21:12, 10 Nov 2010 | alang | 動作 | ||
plugpbx-fop.png PlugPBX - FOP | 50.6 KB | 21:12, 10 Nov 2010 | alang | 動作 | ||
plugpbx-freepbx.png PlugPBX - FreePBX | 189.66 KB | 21:13, 10 Nov 2010 | alang | 動作 | ||
plugpbx-home.png PlugPBX - Home | 56.04 KB | 21:12, 10 Nov 2010 | alang | 動作 | ||
plugpbx-munin.png PlugPBX - Munin | 36.47 KB | 21:13, 10 Nov 2010 | alang | 動作 | ||
plugpbx-phpsysinfo.png PlugPBX - Sysinfo | 51.87 KB | 21:13, 10 Nov 2010 | alang | 動作 | ||
plugpbx-webmin.png PlugPBX - Webmin | 39.54 KB | 21:13, 10 Nov 2010 | alang | 動作 |
Images 7 | ||
---|---|---|
PlugPBX - ARIplugpbx-ARI.png | PlugPBX - FOPplugpbx-fop.png | PlugPBX - FreePBXplugpbx-freepbx.png |
PlugPBX - Homeplugpbx-home.png | PlugPBX - Muninplugpbx-munin.png | PlugPBX - Sysinfoplugpbx-phpsysinfo.png |
PlugPBX - Webminplugpbx-webmin.png |