|
I will quickly summarize in this post on how to hack an inexpensive Seagate DockStar device ($24.99 from Buy + Free S/H) to run a plain-vanilla FreeSwitch v1.0.6.
WARNING: WHEN YOU RECEIVE YOUR SEAGATE DOCKSTAR DEVICE, PLEASE DON'T CONNECT IT TO A LIVE INTERNET UNLESS YOU HAVE DISABLE THE hbmgr.sh BY EDITING /etc/init.d/rcS FILE AS SHOWN IN BLOG. DOING SO WILL LET IT TO PHONE HOME TO PERFORM AN UPGRADE WITH A NEW FIRMWARE THAT HAS TELNET/SSH DISABLED AND AN UNKNOWN root PASSWORD. The only two ways to regain access the root account is either through a serial-console or activate your Seagate DockStar device to subscribe to a 1-year free subscription service to PogoPLUG firm to enable the SSH.
If you don't already know, a Seagate DockStar device is a Sheeva Plug computer runs on an ARM CPU clocked @1.2GHz with 128/256MB RAM/Flash, 4 USB2 ports (3 standard and 1 mini for a Seagate FreeAgent USB hard drive), and an RJ45 port (10/100/1000Mbps). The 256MB NAND/Flash drive is divided into two partitions, i.e. 32MB and 224MB. See the output of dmesg below. The original Seagate DockStar firmware is located on the 32MB partition. This leaves the 224MB partition un-used.
Since this device comes with a built-in of 4 USB2 ports, the easier way to hack this device to run an open-source firmware, i.e. OpenWRT, etc., is to let it boot off of an external USB partition. Unfortunately, the original u-boot manager doesn't have a capability to access any of the USB2 ports; however, it can be configured to boot off of the 224MB un-used partition. If we can sacrifice the emptied 224MB partition to hold a new u-boot manager that has a capability to access/detect any of the USB2 ports, then we can make a Seagate DockStar device to boot off of an external USB partition that contains other OS. To do this, I followed the step-by-step Pogoplug Setboot instructions. This will make a Seagate DockStar device to toggle boot between its original firmware on the internal NAND/Flash drive and a new firmware on an external USB partition. Once the original u-boot manager on a Seagate DockStar device has been reconfigured to boot off of its 224MB partition that contains a new u-boot manager, the rest is to prepare an external USB device with the choice of OS and application. For my needs, I go with an OpenWRT as the OS platform and FreeSwitch as one of the applications.
Here is the screen dumps from my Seagate DockStar device running an OpenWRT OS with FreeSwitch:
Connected to 192.168.1.123.Escape character is '^]'. === IMPORTANT ============================ Use 'passwd' to set your login password this will disable telnet and enable SSH ------------------------------------------ BusyBox v1.16.2 (2010-07-04 06:54:02 EDT) built-in shell (ash)Enter 'help' for a list of built-in commands. _______ ________ __ | |.-----.-----.-----.| | | |.----.| |_ | - || _ | -__| || | | || _|| _| |_______|| __|_____|__|__||________||__| |____| |__| W I R E L E S S F R E E D O M KAMIKAZE (bleeding edge, r22055) ------------------ * 10 oz Vodka Shake well with ice and strain * 10 oz Triple sec mixture into 10 shot glasses. * 10 oz lime juice Salute! ---------------------------------------------------root@DockStar:/# uname -aLinux DockStar 2.6.30.10 #1 Sun Jul 4 09:29:53 EDT 2010 armv5tel GNU/Linuxroot@DockStar:/# free total used free shared buffers Mem: 127260 20660 106600 0 96 Swap: 250104 0 250104Total: 377364 20660 356704root@DockStar:/# fs_cli _____ ____ ____ _ ___ | ___/ ___| / ___| | |_ _| | |_ \___ \ | | | | | | | _| ___) | | |___| |___ | | |_| |____/ \____|_____|___| ******************************************************** Anthony Minessale II, Ken Rice, Michael Jerris ** FreeSWITCH (http://www.freeswitch.org) ** Paypal Donations Appreciated: paypal@freeswitch.org ** Brought to you by ClueCon http://www.cluecon.com/ ******************************************************** Type /help <enter> to see a list of commands +OK log level [7]freeswitch@internal> sofia status Name Type Data State================================================================================================= internal profile sip:mod_sofia@192.168.1.123:5060 RUNNING (0) 192.168.1.123 alias internal ALIASED external profile sip:mod_sofia@192.168.1.123:5080 RUNNING (0) external::17471234567 gateway sip:17471234567@proxy01.sipphone.com REGED=================================================================================================2 profiles 1 alias freeswitch@internal>
Here is the output of a dmesg dump from an original Seagate DockStar firmware:
[ 0.000000] Linux version 2.6.22.18 (bdietrich@brad-ux) (gcc version 4.2.1) #57 Mon Aug 31 16:31:01 PDT 2009[ 0.000000] CPU: ARM926EJ-S [56251311] revision 1 (ARMv5TE), cr=00053177[ 0.000000] Machine: Feroceon-KW[ 0.000000] Using UBoot passing parameters structure[ 0.000000] Memory policy: ECC disabled, Data cache writeback[ 0.000000] On node 0 totalpages: 32768[ 0.000000] DMA zone: 256 pages used for memmap[ 0.000000] DMA zone: 0 pages reserved[ 0.000000] DMA zone: 32512 pages, LIFO batch:7[ 0.000000] Normal zone: 0 pages used for memmap[ 0.000000] CPU0: D VIVT write-back cache[ 0.000000] CPU0: I cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets[ 0.000000] CPU0: D cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets[ 0.000000] Built 1 zonelists. Total pages: 32512[ 0.000000] Kernel command line: console=ttyS0,115200 root=/dev/mtdblock2 ro[ 0.000000] PID hash table entries: 512 (order: 9, 2048 bytes)[ 0.000000] Console: colour dummy device 80x30[ 0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)[ 0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)[ 0.000000] Memory: 128MB 0MB 0MB 0MB = 128MB total[ 0.000000] Memory: 125824KB available (3588K code, 252K data, 120K init)[ 0.000000] Calibrating delay loop... 1192.75 BogoMIPS (lpj=5963776)[ 0.240000] Mount-cache hash table entries: 512[ 0.240000] CPU: Testing write buffer coherency: ok[ 0.240000] NET: Registered protocol family 16[ 0.240000] [ 0.240000] CPU Interface[ 0.240000] -------------[ 0.240000] SDRAM_CS0 ....base 00000000, size 128MB [ 0.240000] SDRAM_CS1 ....disable[ 0.240000] SDRAM_CS2 ....disable[ 0.240000] SDRAM_CS3 ....disable[ 0.240000] PEX0_MEM ....base e8000000, size 128MB [ 0.240000] PEX0_IO ....base f2000000, size 1MB [ 0.240000] INTER_REGS ....base f1000000, size 1MB [ 0.240000] NFLASH_CS ....base fa000000, size 2MB [ 0.240000] SPI_CS ....base f4000000, size 16MB [ 0.240000] BOOT_ROM_CS ....no such[ 0.240000] DEV_BOOTCS ....no such[ 0.240000] CRYPT_ENG ....base f0000000, size 2MB [ 0.240000] [ 0.240000] Marvell Development Board (LSP Version KW_LSP_4.2.7_patch21_with_rx_desc_tuned)-- SHEEVA PLUG Soc: 88F6281 A0 LE[ 0.240000] [ 0.240000] Detected Tclk 200000000 and SysClk 400000000 [ 0.240000] MV Buttons Device Load[ 0.240000] Marvell USB EHCI Host controller #0: c0537600[ 0.740000] PEX0 interface detected no Link.[ 0.740000] PCI: bus0: Fast back to back transfers enabled[ 0.740000] SCSI subsystem initialized[ 0.740000] usbcore: registered new interface driver usbfs[ 0.740000] usbcore: registered new interface driver hub[ 0.740000] usbcore: registered new device driver usb[ 0.740000] NET: Registered protocol family 2[ 0.750000] Time: kw_clocksource clocksource has been installed.[ 0.840000] IP route cache hash table entries: 1024 (order: 0, 4096 bytes)[ 0.840000] TCP established hash table entries: 4096 (order: 3, 32768 bytes)[ 0.840000] TCP bind hash table entries: 4096 (order: 2, 16384 bytes)[ 0.840000] TCP: Hash tables configured (established 4096 bind 4096)[ 0.840000] TCP reno registered[ 0.870000] RTC has been updated!!![ 0.870000] RTC registered[ 0.870000] Use the XOR engines (acceleration) for enhancing the following functions:[ 0.870000] o RAID 5 Xor calculation[ 0.870000] o kernel memcpy[ 0.870000] o kenrel memzero[ 0.870000] Number of XOR engines to use: 4[ 0.870000] cesadev_init(c00116b4)[ 0.870000] mvCesaInit: sessions=640, queue=64, pSram=f0000000[ 0.870000] MV Buttons Driver Load[ 0.870000] squashfs: version 3.3 (2007/10/31) Phillip Lougher[ 0.870000] squashfs: LZMA suppport for slax.org by jro[ 0.870000] JFFS2 version 2.2. (NAND) © 2001-2006 Red Hat, Inc.[ 0.870000] io scheduler noop registered[ 0.870000] io scheduler anticipatory registered (default)[ 0.890000] Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled[ 0.890000] serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A[ 0.900000] serial8250.0: ttyS1 at MMIO 0xf1012100 (irq = 34) is a 16550A[ 0.900000] RAMDISK driver initialized: 16 RAM disks of 16384K size 1024 blocksize[ 0.910000] Loading Marvell Ethernet Driver:[ 0.920000] o Cached descriptors in DRAM[ 0.920000] o DRAM SW cache-coherency[ 0.920000] o Single RX Queue support - ETH_DEF_RXQ=0[ 0.930000] o Single TX Queue support - ETH_DEF_TXQ=0[ 0.940000] o TCP segmentation offload enabled[ 0.940000] o Receive checksum offload enabled[ 0.940000] o Transmit checksum offload enabled[ 0.950000] o Network Fast Processing (Routing) supported[ 0.960000] o Driver ERROR statistics enabled[ 0.960000] o Driver INFO statistics enabled[ 0.960000] o Proc tool API enabled[ 0.970000] o Rx descripors: q0=128[ 0.970000] o Tx descripors: q0=532[ 0.980000] o Loading network interface(s):[ 0.980000] o eth0, ifindex = 1, GbE port = 0[ 0.990000] o eth1, ifindex = 2, GbE port = 1[ 0.990000] [ 1.000000] mvFpRuleDb (c7ed5000): 1024 entries, 4096 bytes[ 1.000000] Intel(R) PRO/1000 Network Driver - version 7.3.20-k2-NAPI[ 1.010000] Copyright (c) 1999-2006 Intel Corporation.[ 1.010000] e100: Intel(R) PRO/100 Network Driver, 3.5.17-k4-NAPI[ 1.020000] e100: Copyright(c) 1999-2006 Intel Corporation[ 1.020000] [ 1.020000] Warning Sata is Powered Off[ 1.030000] NFTL driver: nftlcore.c $Revision: 1.98 $, nftlmount.c $Revision: 1.41 $[ 1.040000] NAND device: Manufacturer ID: 0x2c, Chip ID: 0xda (Micron NAND 256MiB 3,3V 8-bit)[ 1.050000] Scanning device for bad blocks[ 1.150000] Using static partition definition[ 1.150000] Creating 4 MTD partitions on "nand_mtd":[ 1.160000] 0x00000000-0x00100000 : "u-boot"[ 1.160000] 0x00100000-0x00500000 : "uImage"[ 1.170000] 0x00500000-0x02500000 : "root"[ 1.170000] 0x02500000-0x10000000 : "data"[ 1.180000] ehci_marvell ehci_marvell.70059: Marvell Orion EHCI[ 1.180000] ehci_marvell ehci_marvell.70059: new USB bus registered, assigned bus number 1[ 1.220000] ehci_marvell ehci_marvell.70059: irq 19, io base 0xf1050100[ 1.240000] ehci_marvell ehci_marvell.70059: USB 2.0 started, EHCI 1.00, driver 10 Dec 2004[ 1.240000] usb usb1: configuration #1 chosen from 1 choice[ 1.250000] hub 1-0:1.0: USB hub found[ 1.250000] hub 1-0:1.0: 1 port detected[ 1.370000] ohci_hcd: 2006 August 04 USB 1.1 'Open' Host Controller (OHCI) Driver[ 1.370000] USB Universal Host Controller Interface driver v3.0[ 1.650000] usb 1-1: new high speed USB device using ehci_marvell and address 2[ 1.800000] usb 1-1: configuration #1 chosen from 1 choice[ 1.800000] hub 1-1:1.0: USB hub found[ 1.810000] hub 1-1:1.0: 4 ports detected[ 2.160000] usb 1-1.2: new high speed USB device using ehci_marvell and address 3[ 2.260000] usb 1-1.2: configuration #1 chosen from 1 choice[ 2.270000] usbcore: registered new interface driver usblp[ 2.270000] drivers/usb/class/usblp.c: v0.13: USB Printer Device Class driver[ 2.280000] Initializing USB Mass Storage driver...[ 2.280000] scsi0 : SCSI emulation for USB Mass Storage devices[ 2.290000] usbcore: registered new interface driver usb-storage[ 2.300000] USB Mass Storage support registered.[ 2.300000] usb-storage: device found at 3[ 2.300000] usb-storage: waiting for device to settle before scanning[ 2.300000] mice: PS/2 mouse device common for all mice[ 2.310000] i2c /dev entries driver[ 2.310000] Linux telephony interface: v1.00[ 2.310000] md: linear personality registered for level -1[ 2.320000] md: raid0 personality registered for level 0[ 2.330000] md: raid1 personality registered for level 1[ 2.500000] raid6: int32x1 97 MB/s[ 2.670000] raid6: int32x2 114 MB/s[ 2.840000] raid6: int32x4 122 MB/s[ 3.010000] raid6: int32x8 110 MB/s[ 3.010000] raid6: using algorithm int32x4 (122 MB/s)[ 3.010000] md: raid6 personality registered for level 6[ 3.020000] md: raid5 personality registered for level 5[ 3.020000] md: raid4 personality registered for level 4[ 3.030000] raid5: measuring checksumming speed[ 3.080000] arm4regs : 1071.200 MB/sec[ 3.130000] 8regs : 754.800 MB/sec[ 3.180000] 32regs : 899.600 MB/sec[ 3.180000] raid5: using function: arm4regs (1071.200 MB/sec)[ 3.190000] device-mapper: ioctl: 4.11.0-ioctl (2006-10-12) initialised: dm-devel@redhat.com[ 3.190000] dm_crypt using the OCF package.[ 3.200000] sdhci: Secure Digital Host Controller Interface driver[ 3.200000] sdhci: Copyright(c) Pierre Ossman[ 3.210000] usbcore: registered new interface driver usbhid[ 3.210000] drivers/hid/usbhid/hid-core.c: v2.6:USB HID core driver[ 3.220000] TCP cubic registered[ 3.220000] NET: Registered protocol family 1[ 3.230000] NET: Registered protocol family 17[ 3.230000] md: Autodetecting RAID arrays.[ 3.240000] md: autorun ...[ 3.240000] md: ... autorun DONE.[ 5.110000] Empty flash at 0x00de8e44 ends at 0x00de9000[ 8.800000] VFS: Mounted root (jffs2 filesystem) readonly.[ 8.800000] Freeing init memory: 120KI hope this has inspired you to invest your $24.99 for your own Seagate DockStar device to host your own PBX system. I may not be able to get an asterisk-1.6.x properly hosted on a Seagate DockStar device running an OpenWRT OS, but that doesn't mean it is not possible. After all, this has been a very inexpensive way to own a PBX system.
[EDIT]: By now, I believe some of you have already received your Seagate DockStar device from Buy. So, I have attached the OpenWRT SVN firmware (contains the uImage Linux kernel, OpenWRT firmware, FreeSwitch v1.0.6, and other utilities) in a tarball file for you to use on your Seagate DockStar device (only if you wish).
In order to use the above firmware, you MUST mod your Seagate DockStar device so that it will load a firmware from an external USB storage. This can be done in two ways, i.e. using a PogoPlug Setboot as shown here or installing a new OpenWRT firmware on its internal NAND/Flash partition as shown here. My preference is to use a PogoPlug SetBoot, YMMV. If you use a PogoPlug SetBoot option, then follow the following steps to complete the installation:
1. Follow the PogoPlug SetBoot step-by-step instructions all the way to step #2c. This will enable your device to boot a firmware on an external USB partition.2. Get a USB storage device (at least 100MB+, preferrably 256MB+) and format it with an EXT3 filesystem (similar to step #3 shown in PogoPlug SetBoot step-by-step instructions). I use Linux tar utility to untar the tarball file into my USB storage device mounted on /mnt (tar -jxf openwrt-kirkwood-rootfs.tar.bz2 -C /mnt).3. Plug the USB storage to your Seagate Dockstar device and power it up.4. Login into your Seagate DockStar device (you will need to find its IP Address from your router). Once logged into your device, type reboot to perform a reboot. The PogoPlug SetBoot approach will make a Seagate DockStar device to toggle booting between the original firmware and a new firmware found on an external USB storage.5. You can use a telnet utiility (no SSH yet as of this moment) to log into your Seagate DockStar device once it has finished booting. At this stage, no need for a username/password. Once you have logged into your Seagate DockStar device running a new OpenWRT SVN firmware, you can change its root password by using the 'passwd' utility. Just type passwd and hit return. Then, you will be prompted to enter for a new password as well as its confirmation. Once you have secured your device with a new root password, the next login MUST be done using a secured shell login, i.e. ssh (on Linux) or putty (on windows).6. By now, you can use a ps utility to see a lot of freeswitch processes are running. Execute fs_cli to get into freeswitch console. Once in the Freeswitch console, you can type /bye to exit to the shell.7. For further information on how to configure, operate, and maintain a FreeSwitch PBX system, please read the FreeSwitch Doc. Have fun and enjoy with your new FreeSwitch PBX system.
The following is a list of files I have attached here: OpenWRT SVN tarball firmware file, .config file to configure OpenWRT SVN source, and config-default file to configure Linux kernel for OpenWRT SVN, respectively. Please rename the config file to .config (the system didn't let me upload a .config file name).
[attachment=1]
[attachment=2]
[attachment=3]
--
don't and stop are the ONLY two 4-letter words considered offensive to men, but not when used together.
more info [Other] Own a FreeSwitch on a Seagate DockStar for $24.99
|