Apr 292011
 
Attention! This is an advanced topic! Do not engage in any activity if you’re not cool with the Linux command line and ready to do something to your GoFlex Home that Seagate did not intend you to do! I’ve warned you.


The section describing the basic system setup is out of date as of 2013-06-05. Please refer to http://archlinuxarm.org/platforms/armv5/seagate-goflex-home for up-to-date information.

The Hardware

Best image on the hardware:
The inside of the Seagate GoFlex Home
Full size: http://img641.imageshack.us/img641/3348/seagategoflexhomebasein.jpg | More images to be found in the Beyond Logic Wiki.

It’s a fairly standard hardware platform commonly found in many consumer NAS products:

Type Component Used in Seagate GoFlex Home
CPU Marvell “Kirkwood” 88F6281 @ 1.2GHz (ARM926EJ-S) (ARMv5 (ARM9) based)
Ram 128 MB (Nanya NT5TU64M16DG-AC, 64M x 16, 400MHz, 5-5-5)
Flash 512 MB
Network 10/100/1000 Marvell 88E1116R Gigabit Ethernet
USB 1x USB 2.0 Marvell Orion EHCI
HDD Seagate ST31000528AS (1TB Version)

Information from the running Plugbox Linux system (that’s what it was called when I started this post – now its Arch Linux ARM):

More on the hard and software of the GoFlex Home: http://archlinuxarm.org/platforms/armv5/seagate-goflex-home.
The GoFlex Home has a cryptographic hardware accelerator built right into its Kirkwood SoC: http://wiki.openwrt.org/toh/seagate/dockstar#crypto.hardware.acceleration.

See the thread Hardware Cryptography for Kirkwood in the ArchLinuxARM forum, Sebastien Lucas’ blog post “Dockstar et ArchLinux : tout ça pour l’accélération matérielle” from his blog Technology and me and my speedup log for OpenSSL. See my alarm forum post and this French blog post.

Initial installation of Arch Linux ARM (was: Plugbox Linux)

Arch Linux ARM / Plugbox Linux is based on Arch Linux so you can find a lot of information on their wiki.

This section is outdated as it describes the installation of the former Plugbox Linux. As of 2012-03-01 you want to install Arch Linux ARM and the instructions can be found on http://archlinuxarm.org/platforms/armv5/seagate-goflex-home (click on Installation there).

First connect your GoFlex Home to a router (it must receive an IP automatically via DHCP). Run the wizard on the website of the device (needs Internet connectivity – I had no problems with that) and create a user. Then connect using SSH on the terminal (XXXX-XXXX-XXXX-XXXX is the product key on the backside):

ssh USERNAME_hipserv2_seagateplug_XXXX-XXXX-XXXX-XXXX@YOUR_IP_ADDRESS

To gain root access run:

sudo -E -s

Now disable updates:

chmod -x /usr/bin/oe-update-checker
chmod -x /etc/cron.daily/update-checker
chmod -x /etc/cron.hourly/update-checker
chmod -x /etc/init.d/openvpn
chmod -x /usr/sbin/openvpn
chmod -x /var/www/admin/sshtunnel.pl

Install UBIT (when repeating this step later – so when Plugbox Linux is allready installed on the GoFlex – you must make sure, cpio is installed by running pacman -Sy cpio beforehand):

# Download the U-Boot Install Toolkit (UBIT) environment
cd /tmp
wget http://jeff.doozan.com/debian/goflex/v0.6/uInitrd
wget http://jeff.doozan.com/debian/goflex/v0.6/ubit_start
chmod +x ubit_start

Start the UBIT environment where the prompt will read ubit0-6:~#:

./ubit_start

Install uboot and prepare your HDD for Plugbox Linux to be installed:

uboot_uptodate
chain_install goflexhome
fdisk /dev/sda
# and enter `p`, `d 1`, `p`, `n`, `p`, `1`, then `ENTER` (default values) finally `w`.
# Note: U-Boot does have partition size limitations.
# If your install doesn't work on a large (1TB+ drive) try creating a small (~32GB) boot partition instead.

mke2fs -j /dev/sda1

Download the Plugbox tarball and unpack the Plugbox tarball (this will take a long time):

on /dev/sda1 wget http://plugboxlinux.org/os/2011.02/PlugApps-Linux-2011.02-rootfs.tar.gz -O rootfs.tar.gz
on /dev/sda1 tar -xzvf rootfs.tar.gz

You need to set the MAC address to the value printed on the back side label of your GoFlex Home:

ethaddr uu:vv:ww:xx:yy:zz

Still on the UBIT prompt: install the rescue system and mark the partition with the special label “rootfs”

on /dev/sda1 ubit_write
tune2fs -L "rootfs" /dev/sda1

Leave the UBIT shell and reboot the device

exit
/sbin/reboot

Run a full system update

pacman -Scc  
pacman -Syyuf

In case of problems have a look at https://gist.github.com/946214#file_netconsole_debugging.log.

Prepare the HDD on an different system

Connect the HDD to a different Linux computer and run the following commands:

cd /media/boothdd
sudo wget http://plugboxlinux.org/os/2011.02/PlugApps-Linux-2011.02-rootfs.tar.gz -O rootfs.tar.gz
sudo tar -xzvf rootfs.tar.gz

U-Boot rescue terminal

http://forum.doozan.com/read.php?2,4083,4417#msg-4417
http://archlinuxarm.org/forum/viewtopic.php?p=4447#p4447

Format a usb stick with ext3 and get ubit boot files and modules:

cd /media/stick
sudo wget http://jeff.doozan.com/debian/goflex/v0.6/v2.6.37/boot.tar.gz
sudo wget http://jeff.doozan.com/debian/goflex/v0.6/v2.6.37/modules.tar.gz
sudo tar -xf boot.tar.gz
sudo tar -xf modules.tar.gz
cp -R ./lib/modules/2.6.37-ubit-01715-g1e5cda0/* /lib/modules/
cd ..
sudo umount /media/stick

Going back to the original Firmware

The following site describes how to get the official firmware back on your Goflex Home:
http://support.goflexhome.hipserv.com/en/reflash/index.html

Creating a Linux User Account

https://wiki.archlinux.org/index.php/Users_and_Groups#User_management

useradd -m -g users -G audio,lp,optical,storage,video,wheel,games,power,scanner -s /bin/bash philipp

Jumbo Frames (MTU > 1500)

https://wiki.archlinux.org/index.php/Jumbo_Frames

The linux driver mv643xx_eth for the Marvell Ethernet Controller has support for jumbo frames (MTUs > 1500). However, hardware support for checksum calculation is only available up the MTU 1600 on the Kirwood architecture.
I don’t know if this is a limitation of the Ethernet controller, as the the ASUS NAS-M25a and the Synology DS211+ b support jumbo frames officially (both using the Marvell 88E1116R Gigabit Ethernet Controller).

I tested to set the MTU to 4000 bytes:

ifconfig eth0 mtu 4000

To check the current value for the MTU run this:

 ifconfig eth0 | grep MTU

I could increase the speed of a file transfer via SSH by ~10 % when the MTU was set to 4000 (on my computer and the GoFlex Home connected via a jumbo frame capable Netgear GS105 Gigabit Switch).

To test, if your jumbo packages get through, you can use the ping command ping -D -s 3800 IP_OF_GOFLEX (should be something like ping IP_OF_GOFLEX -f -l 3800 on Windows).

Controlling the LEDs

http://forum.doozan.com/read.php?2,4638,4645,quote=1

There are two control files for the LEDs in /sys/class/leds:

  • status:green:health and
  • status:orange:fault.

Examples:

echo heartbeat > /sys/class/leds/status\:green\:health/trigger
echo default-on > /sys/class/leds/status\:orange\:fault/trigger
echo none > /sys/class/leds/status\:orange\:fault/trigger

Since version 1.4.9 iptables directly supports led indicators in order to let you see arriving Ethernet packages:

pacman -Sy iptables
modprobe xt_LED

Set up a rule to blink the orange LED when you receive incoming SSH traffic:

iptables -A INPUT -p tcp --dport 22 -j LED --led-trigger-id ssh --led-delay 100
echo netfilter-ssh > /sys/class/leds/status\:orange\:fault/trigger

If you want a the green LED off and the orange on when a shutdown is finished (safe to remove any drives), add the following two lines at the end of your /etc/init.d/halt:

echo none > /sys/class/leds/status\:green\:health/trigger
echo default-on > /sys/class/leds/status\:orange\:fault/trigger

For more in-depth information on the LEDs, have a look at the additional file arch/arm/mach-kirkwood/goflexhome-setup.c in the Linux kernel as added in the ArchLinuxARM kernel patch file.
One may also be able to use the Sysfs Interface for Userspace framework in the linux kernel (GPIO SYSFS: /sys/class/gpio). Introductory information on this can be found in the section “Sysfs Interface for Userspace” of http://www.kernel.org/doc/Documentation/gpio.txt. The usage of it is well described on http://www.avrfreaks.net/wiki/index.php/Documentation:Linux/GPIO and on http://squidge.sourceforge.net/gpio/. I don’t know yet how to enable it.

Setting your Timezone

See https://wiki.archlinux.org/index.php/Time#Time_Zone

# To check the current zone:
timedatectl status
# To list available zones (exit with 'q'):
timedatectl list-timezones
# To set your time zone run:
timedatectl set-timezone Europe/Berlin

Controlling the hardware clock

https://wiki.archlinux.org/index.php/Network_Time_Protocol_daemon

On my box, the hardware clock was off quite a bit and I don’t like the hwclock daemon. So I installed ntpd to synchronize time with NTP service automatically, replaced the hwclock daemon with it and set up a cron job to update the hardware clock accordingly:

pacman -S ntp

(On older installations I’d update my /etc/rc.conf to DAEMONS=(!hwclock ntpd [...]). Not needed anymore as of 2012-12.)

And my crontab -e:

# Set the hwclock to an NTP synced system clock:
#47 */12 * * * ntpd -s; hwclock -w
47 */12 * * * hwclock -w

Hard Disk Spindown

https://bbs.archlinux.de/viewtopic.php?id=17359

Manually force a spindown on the SATA drive:

hdparm -y /dev/sda

or on a connected USB hard disk:

sdparm --flexible --command=stop /dev/sdb

Package Management with Plugbox Linux

http://archlinuxarm.org/support/guides/applications/package-management

Install OpenVPN

https://wiki.archlinux.org/index.php/OpenVPN

pacman -Sy openvpn

Set up NFS

http://wiki.archlinux.org/index.php/Nfs

Install the packages for a NFS server:

 pacman -Sy nfs-utils rpcbind

Relevant configuration files:

  • /etc/conf.d/nfs-common.conf
  • /etc/conf.d/nfs-server.conf

Plugbox Linux automatically mounts all partitions. To get the NAS partition mounted explicitly, add it to /etc/fstab:

/dev/sda3    /NASdata    ext3    defaults    0    0

(You might need to create the mountpoint), mount it and change the user rights (anyone may read and write):

mkdir /NASdata
mount /NASdata
chmod 777 /NASdata

Set up the exports using vi /etc/exports to enable network access to the storage:

/NASdata 192.168.1.1/24(rw,async,insecure,no_subtree_check)

This makes the folder writable for all clients in the network 192.168.1.1/24 (192.168.1.1 to 192.168.1.254).

And allow this network in /etc/hosts.allow:

nfsd: 192.168.1.0/255.255.255.0
rpcbind: 192.168.1.0/255.255.255.0
mountd: 192.168.1.0/255.255.255.0

Start the daemons when booting by adding the list rpcbind, nfs-common und nfs-server to the DAEMONS in /etc/rc.conf. For example:

DAEMONS=(syslog-ng network netfs crond sshd openntpd rpcbind nfs-common nfs-server)

Reboot. Now you can mount the folder using:

mkdir mountpoint
mount 192.168.1.42:/NASdata ./mountpoint

Setting It up as a Log Host for Syslog

Check out this blog post.

Transmission BT client

http://archlinuxarm.org/support/guides/applications/transmission

pacman -Sy transmission-cli

If you want to run the Transmission daemon at boot, add transmissiond to the DAEMONS array in /etc/rc.conf. You have to set the user in /etc/conf.d/transmissiond.

adduser torrent
TRANSMISSION_HOME=/NASdata
cat << EOF >> /etc/conf.d/transmissiond 
TRANSMISSION_HOME=$TRANSMISSION_HOME
TRANS_USER="torrent"
TRANS_ARGS="-g $TRANSMISSION_HOME/.config/transmission-daemon"
EOF

Change the configuration file:

# Create the configuration file by starting and stopping the daemon:
/etc/rc.d/transmissiond start && /etc/rc.d/transmissiond stop
# Edit the main configuration file:
vi /NASdata/.config/transmission-daemon/settings.json
# set "rpc-whitelist-enabled" to false.

To start the transmission daemon manually run:

/etc/rc.d/transmissiond start

To run Transmission on startup, add transmissiond to the DAEMONS in /etc/rc.conf:

vi /etc/rc.conf

The web configuration interface is then available on http://plug.ip.address:9091

Firefly Media Server

Attention! This mt-daapd / Firefly Media Server does not work with newer iTunes versions (iTunes keeps breaking compatibility with mt-daapd and it’s always a fight to get it back working). I don’t use it anymore!

pacman -Sy dbus mt-daapd
vi /etc/mt-daapd/mt-daapd.conf
  • Change to admin_pw to a unique password.
  • Change the mp3_dir to your folder filled with MP3s on your external hard drive.
  • Change the servername to something you like. (This is what comes up in iTunes. I set it to goflex.)
  • Change runas to root.

Starting the Firefly Media Server manually:

/etc/rc.d/dbus start && /etc/rc.d/avahi-daemon start && /etc/rc.d/mt-daapd start

Add dbus avahi-daemon mt-daapd to the DAEMONS in /etc/rc.conf to start it automatically at startup.

The web configuration interface is then available on http://plug.ip.address:3689/

Afterwards it should appear in iTunes as a share. You can also add it to XMBC by adding an audio source: Zeroconf → goflex (iTunes Music Sharing) and you will get a path such as daap://your.ip:3689/goflex/ .

Apache, MySQL and PHP

http://lifehacker.com/#!5637092/turn-a-pogoplug-into-a-fully+featured-linux-web-server

pacman -Sy apache mysql php

For the installation log (containing hints on setting the MySQL password etc.) see https://gist.github.com/949765#file_lamp_installation_plugbox_linux.log.

iSCSI (not working yet)

The information on iSCSI below is outdated as of 2013-02-11. Check out https://wiki.archlinux.org/index.php/ISCSI_Target for more information.

http://archlinuxarm.org/forum/viewtopic.php?p=4680#p4680
http://blog.philippklaus.de/2011/04/iscsi-on-ubuntu-linux/ http://en.wikipedia.org/wiki/LIO_Target

pacman -Sy iscsitarget-svn

Change the iSCSI configuration. cat /etc/iet/ietd.conf:

iSNSServer 192.168.1.21
iSNSAccessControl No
IncomingUser joe secret
OutgoingUser jack 12charsecret

iqn.2014-04.com.example:storage
  #Lun 0 Path=/dev/sda3,Type=fileio
  Lun 0 Path=/dev/sda3,Type=blockio

cat /etc/iet/initiators.allow:

iqn.2014-04.com.example:storage 192.168.1.1/24

restart the iscsi target service:

/etc/rc.d/iscsi-target stop
/etc/rc.d/iscsi-target start

Currently this produces the error:

FATAL: Module iscsi_trgt not found.

open-iscsi (which is an iSCSI Initiator – a client that accesses an iSCSI target device and makes it available on the local system):

PlugUI

http://archlinuxarm.org/forum/viewtopic.php?f=3&t=911

pacman -Sy plugui

After it installs, start it up with:

/etc/rc.d/plugui start

The Plug UI will be served as web site on port 80.

If you go to System → About Plug in the PlugUI, it gives you some information on the hardware:

Plug information / About your Device
Device: Seagate GoFlex Home
Processor: Feroceon 88FR131 rev 1 (v5l)
Architecture: armv5tel
Kernel: Linux 2.6.38 #1 PREEMPT Thu Apr 21 11:14:23 MDT 2011

MiniDLNA

http://archlinuxarm.org/support/guides/applications/minidlna

MiniDLNA is a slim DLNA media server for photos, music and videos. You may install it via PlugUI or in Terminal (check the link above).

After you installed MiniDLNA, set the media directory and started it up, you can view your media via XBMC (in my case on a Mac) by adding an audio source: UPnP Devices → PlugApps: root. This will show you a path like UPNP://4D696E69-444C-164E-9D41-0010759629C8 which you can add and then you are able to play music from this source.

AFP and Time Machine support

http://archlinuxarm.org/support/guides/applications/time-machine
http://archlinuxarm.org/forum/viewtopic.php?f=15&t=518
https://wiki.archlinux.org/index.php/Netatalk

Check the dedicated blog post Set up an AFP Server for Apple Time Machine. Here are the basics:

# Install Netatalk and its dependencies:
pacman -Sy netatalk avahi dbus
# Let's start setting it all up:
echo "afpd: ALL" >> /etc/hosts.allow
echo " - -transall -uamlist uams_randnum.so,uams_dhx2.so -nosavepassword -advertise_ssh" >> /etc/netatalk/afpd.conf
sed -i "s|#enable-dbus=yes|enable-dbus=yes|g" /etc/avahi/avahi-daemon.conf
# Is this needed? I don't know but it doesn't hurt:
echo "AVAHI_DAEMON_START=1" > /etc/default/avahi-daemon
# Now let's create a directory for TimeMachine backups:
mkdir -p /NASdata/TimeMachine
echo '/NASdata/TimeMachine "Time Machine" cnidscheme:cdb options:usedots,upriv,tm' >> /etc/netatalk/AppleVolumes.default
# ^ usedots: required if you want to use invisible files and folders (= starting with a dot)
# ^ upriv: adds support for AFP3 unix file privileges
# Set up the user philipp for use with Netatalk:
touch /etc/netatalk/afppasswd
afppasswd -a philipp
#! Give it permissions to access the TimeMachine folder:
chown philipp /NASdata/TimeMachine
chmod 777 /NASdata/TimeMachine

Add dbus avahi-daemon afpd cnid to your DAEMONS in /etc/rc.conf and restart.

For the upcoming netatalk 3.0 the configuration will be simplified and you have to check the notes in the upgrade guide. Also read the Release Notes for the 3.0-alpha1 (27th of March 2012).

SABnzbd

SABnzbd is an Open Source Binary Newsreader written in Python.
SABnzbd makes Usenet as simple and streamlined as possible by automating everything we can. All you have to do is add an .nzb. SABnzbd takes over from there, where it will be automatically downloaded, verified, repaired, extracted and filed away with zero human interaction.

The installation is pretty straight forward:

pacman -Syyu
pacman -S sabnzbd

My installation log

To start and stop you do

/etc/rc.d/sabnzbd start
/etc/rc.d/sabnzbd stop

The configuration file is /etc/conf.d/sabnzbd (You may want to change the IP to an external one in order to access the web interface via http://ip:8080). You can also add sabnzbd to the DAEMONS list at the end of /etc/rc.conf in order to have it run at system startup.

Running Postfix as MTA on the GoFlex Home

pacman -Syyu
pacman -S postfix

https://wiki.archlinux.org/index.php/Postfix

vsftpd

https://wiki.archlinux.org/index.php/Very_Secure_FTP_Daemon

Although FTP is insecure by design (passwords being transmitted in clear text) I use it to transfer files on to my GoFlex on the local network. It’s the fastest way (~ 30MB/s)!

pacman -S vsftpd

Now change the config file /etc/vsftpd.conf:

  • anonymous_enable=NO
  • local_enable=YES
  • write_enable=YES

start it:

rc.d start vsftpd

and / or add vsftpd to your DAEMONS=() in /etc/rc.conf.

You can also set up its SSL encryption but this will slow it down and means you could just as well use SSH / SFTP.

DownloadDaemon

DownloadDaemon is can be used to get content shared on one-click hosters etc. Also check http://archlinuxarm.org/forum/viewtopic.php?f=4&t=701. Here is how to get it:

pacman -S yaourt
yaourt -S downloaddaemon

Getting USB Sound Cards to Work – Installing Pulseaudio

I had to install Pulseaudio because my sound was crippled and bad via Alsa. Probably there is an easier solution directly via Alsa though: http://archlinuxarm.org/forum/viewtopic.php?p=1742#p1742

https://wiki.archlinux.org/index.php/PulseAudio
https://wiki.archlinux.org/index.php/PulseAudio/Examples More HowTos: For OpenWrt, for Ubuntu, for Gentoo, via Airtunes, about running Pulseaudio system wide, PulseAudio on top of JACK and PulseAudio’s Network Setup

Helpful Posts in the Arch Linux ARM Forum: 1, 2

pacman -S pulseaudio pulseaudio-alsa avahi dbus

Start avahi-daemon and dbus:

rc.d start dbus && rc.d start avahi-daemon

grep resample-method /etc/pulse/daemon.conf

; resample-method=speex-float-0
resample-method = trivial

grep exit-idle-time /etc/pulse/daemon.conf

exit-idle-time = -1

grep native-protocol-tcp /etc/pulse/default.pa:

load-module module-native-protocol-tcp auth-ip-acl=127.0.0.1;192.168.102.0/24 auth-anonymous=1

grep zeroconf-publish /etc/pulse/default.pa:

load-module module-zeroconf-publish

And set up ALSA to use Pulseaudio:

cat << EOF > /etc/asound.conf 
pcm.!default {
    type pulse
}

ctl.!default {
    type pulse
}

# Explicit PulseAudio device
pcm.pulse {
    type pulse
}

ctl.pulse {
    type pulse
}
EOF

ToDo:

  1. Create a /etc/rc.d/pulseaudio file containing something like pulseaudio --start -D -v
  2. Experiment with the sample rate. The current default is 48000 as grep defaults.pcm.dmix.rate /usr/share/alsa/alsa.conf reveals defaults.pcm.dmix.rate 48000.
  3. Trying to reduce lag:

To change to volume of my sound card, I have to run something like pacmd set-sink-volume 5 400 (read this for more information). This can probably also be done via amixer.

Getting the M-Audio Transit USB Sound Card to Work

https://aur.archlinux.org/packages.php?ID=12812
https://wiki.archlinux.org/index.php/ALSA

pacman -S yaourt alsa-utils
yaourt -AS madfuload

Install ShairPort

With Shairport you can stream music from iTunes to your Arch Linux ARM box (running Pulseaudio with a USB sound card being connected). It works great for me!

mkdir -p /root/Downloads
cd /root/Downloads
git clone git://github.com/albertz/shairport.git
cd shairport
make
perl -MCPAN -e shell
# ^ follow the CPAN autoconfiguration...
# then enter:
#  q
# to quit the CPAN shell and open it again (RAM would be a problem otherwise):
perl -MCPAN -e shell
# and install the following:
#  install HTTP::Request
#  install HTTP::Message
#  install Crypt::OpenSSL::RSA
#  install IO::Socket::INET6
#  q

If any of the above commands return an error, you might be missing some of the following packages found here (I had a lot of that stuff installed already): avahi libao openssl perl-libwww perl-crypt-openssl-rsa (or from the Debian list: build-essential libssl-dev libcrypt-openssl-rsa-perl libao-dev libio-socket-inet6-perl libwww-perl avahi-utils pkg-config).

Run ShairPort as the user who started Pulseaudio like this:

perl /root/Downloads/shairport/shairport.pl --ao_driver=pulse --apname=SoundDistributor

More hints: http://archlinuxarm.org/forum/viewtopic.php?p=5737#p5737. Use the option --help to see more configuration options:

perl /home/philipp/Downloads/shairport/shairport.pl --help

After installing Shairport the way described I realized, I would not need pearl: https://github.com/albertz/shairport/issues/133#issuecomment-3404811

Install the Music Player Daemon – MPD

https://wiki.archlinux.org/index.php/Music_Player_Daemon

pacman -S mpd
cp /usr/share/mpd/mpd.conf.example /etc/mpd.conf

Check http://mpd.wikia.com/wiki/Clients for clients. The standard MPD client is mpc.

GLCD2USB LCD Display

GLCD2USB allows you to connect a LCD screen to the USB port. You can display all kinds of stuff on it. See my other blog post.

I had problems getting this to work with lcd4linux.
Serdisplib works though

yaourt -S serdisplib
# edit the PKGBUILD and replace with
# https://gist.github.com/2774176#file_pkgbuild

Test using

testserdisp

More stuff I tried (with no great results):

Install [GraphLCD (also called glcdlib)][http://graphlcd.berlios.de/]

yaourt -S graphlcd-base-svn
# adjust PKGBUILD to accept arm as arch and quickly remove any asm code from
# /var/abs/local/yaourtbuild/graphlcd-base-svn/src/graphlcd-base-build/graphlcd-base/glcddrivers/port.c
# copy http://svn.berlios.de/wsvn/graphlcd/trunk/graphlcd-base/graphlcd.conf
# to /etc/

yaourt -S lcdproc
# adjust PKGBUILD to accept arm as arch

yaourt -S lcd4linux-svn

Temperature measurement using 1w / OneWire sensors

1-Wire (OneWire) is a device communications bus system that you can use for multiple electronic devices like small thermometers such as the DS18S20 / DS18B20 (good overview in German: http://www.mikrocontroller.net/articles/Temperatursensor#DS18S20_.2F_DS18B20).
You may use the USB → Onewire Adapter DS9490R ( In Germany, you can buy it on http://shop.wiregate.de/wiregate/usb-produkte/ds9490r-1-wire-usb-adapter.html) via the OneWire Linux filesystem – owfs.

Don Veino was working on this. See http://veino.com/blog/?p=603. To install owfs (including temploggerd) run pacman -S owfs. Some of the steps Don verified to work are:

owserver -F -s 4304 -d /dev/ttyUSB0
owhttpd -F --readonly -s 4304 -p 3001
mkdir /tmp/1wire
owfs -F -s 4304 /tmp/1wire
ls /tmp/1wire

node-whatsapp

su
pacman -Su nodejs
npm install -g coffee-script
su philipp
cd ~
git clone git://github.com/saschagehlich/node-whatsapp.git
cd node-whatsapp
npm install
coffee ./index.coffee

resources

VN:F [1.9.22_1171]
Rating: 9.2/10 (6 votes cast)
Install ArchLinuxARM on the Seagate GoFlex Home, 9.2 out of 10 based on 6 ratings

Related Posts:

  32 Responses to “Install ArchLinuxARM on the Seagate GoFlex Home”

  1. Tried this. It seemed to work fine until reboot. Now the device won ‘t start and I can’t get into contact with it. Is my GoFlex Home gone for ever? Tried to start it with a rescue USB-stick but that didn’t do anything either. Reset doesn’t do anything.

    VA:F [1.9.22_1171]
    Rating: 0 (from 2 votes)
    • Hello gorade, I assume you were able to successfully install uboot in the ubit shell via uboot_uptodate and chain_install goflexhome, create a partition using fdisk, download PlugApps-Linux-2011.02-rootfs.tar.gz, unpack it on your disk etc.? If this is all worked fine up to this point, I don’t know what the problem is.
      When I was installing Plugbox Linux on my GoFlex Home, I accidentally rebooted right after creating the partition (without unpacking the PlugApps archive file to the disk). Nothing happened on reboot… I then connected the GoFlex Home to my computer via a direct network connection (crossover cable or normal doesn’t matter) and started Wireshark to listen to any events on the network. Using this method, I discovered, that there was some activity on the port: ARP packages asking for the host 10.10.10.5. When I was searching for further information on the internet, I found the Plugbox site on the “netconsole” – http://plugapps.com/index.php5/Monitoring_UBIT_boot_using_netcat . So I set up an interface alias for the IP 10.10.10.5 and listened to incoming data on port 6666 as shown on https://gist.github.com/946214#file_netconsole_debugging.log . As a result, I knew, that uboot was installed correctly but the bootloader was unable to start from the HDD (off course, no operating system was installed). I ended up installing the operating system on the disk using a different computer (connected the HDD via SATA and unpacked said Plugbox archive). When I plugged it in on the GoFlex Home afterwards, everything was fine and the box started Plugbox Linux and received its IP via DHCP so I could start working on it.

      I hope this is of some use for you. If you don’t get any signals from your GoFlex Home at all (no network packages at all using Wireshark or tcpdump), you should search the archives / ask for help in the Plugbox Forum: http://plugapps.com/forum/

      VN:F [1.9.22_1171]
      Rating: 0 (from 0 votes)
      • It seems the installation went well, but then it will not start. No contact wat so ever. Maybe I’ll try to start the HDD with a SATA-cable tomorrow. For now it just stands with the indicator lamp blinking and nothing more happens. I can’t contact it with SSH or with browser. Wrecked?

        VA:F [1.9.22_1171]
        Rating: 0 (from 0 votes)
        • Well, you should definitely give netconsole a try (as said before). Its neither SSH nor HTTP via a browser but rather raw tcp socket communication. As soon as you get this to work, you might be able to debug the problem. I don’t think your device is bricked. When I rebooted before installing Plugbox Linux on the HDD (on a 32 GB ext3 partition) my box wouldn’t stop blinking and I thought it was dead. But as I said with a bit of attention on the network I found out more…

          VN:F [1.9.22_1171]
          Rating: 0 (from 0 votes)
  2. Followed a similar guide on the plugapps wiki for firefly media server; everything appears to be running but I cannot connect to the web interface nor by any other means. Anyone know where I went wrong?

    VA:F [1.9.22_1171]
    Rating: 0 (from 2 votes)
    • Hi Tesseden, I had problems with the mt-daap (Firefly Media Server) when I wrote the guide. However when you posted the comment I tried it again. I first updated all packages using pacman -Syy && pacman -Syu I also checked my configuration file /etc/mt-daapd/mt-daapd.conf (the mp3 folder, the admin password, the runas directive etc.) When I started the daemon (successively ran /etc/rc.d/dbus start , /etc/rc.d/avahi-daemon start and /etc/rc.d/mt-daapd start) I could access the web interface on http:// goflex.ip:3689 and was able to play music via iTunes 10.2.2 (12) on Mac OS X.

      VN:F [1.9.22_1171]
      Rating: 0 (from 2 votes)
  3. Hello Phillip,

    I’m very interested in trying this out my (pretty much by default pretty limited goflex). I’m no expert in Linux but I managed to get up to the part “Install Uboot and prepare your HDD…”

    When I try to perform step3 in there I’m stuck with this message: Calling ioctl() to re-read partition table fdisk: WARNING: rereading partition table failed, kernel still uses old table: Device or resource busy

    Is there an extra step I need to perform to free up resources as the message suggests? If so, what do I need to do at this point?

    Thanks in advance ;)

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  4. Hello Phillip,

    After creating a partition (with 1,000,000 blocks which I figured was 32GB approximately), I tried to create a file system on the partition using mke2fs -j /dev/sda1 However, I got an error message saying the mke2fs would not format a partition that is mounted. I tried to do a umount /dev/sda1, but that did not work because it reported that it could not umount some folders saying they did not exist. I was wondering if there was something missing in your instructions between the fdisk stuff and the mke2fs?

    Thanks,

    Salim.

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
    • Hello salim, when I did that step at that time, I had some trouble too. Can’t remember exactly. I prepared the HDD on a different Linux machine then, put it back and it directly booted. In general, you can’t and don’t want to format a partition that is currently mounted. So you should have another look at your partition table, to see what’s actually going on! A partition that has just been created by fdisk cannot be mounted as it misses a filesystem. I should probably have a closer look at my instructions at this point but currently I don’t have physical access to my box. The safest way to procede, is to take the HDD out of the housing and prepare it on a different machine. Regards, Philipp

      VN:F [1.9.22_1171]
      Rating: 0 (from 0 votes)
  5. Another question I have is how do you connect the drive to a different computer? The connections go through the base.

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
    • Hi Salim! I opened the case, removed the hard disk and connected it to a PC via S-ATA.

      VN:F [1.9.22_1171]
      Rating: 0 (from 0 votes)
  6. Thank you and thank you for your great post.

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  7. One last thing. I could not figure out how to open the case for the goflex home without breaking it. What is the secret :) ? I can see what may be tiny screws on the bottom, but I’m not sure.

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
    • Check uTube. There are a couple of good videos for opening the ‘black box’. Worked just fine.

      VA:F [1.9.22_1171]
      Rating: 0 (from 0 votes)
  8. hi i have a bricked goflex home i have tried every thing for 2 days heres is a u-boot dump can you help cheers

    U-Boot 2010.09 (Feb 16 2011 – 18:44:23) UBIT v0.6 by Jeff Doozan and Peter Carmichael (Re)start USB… USB: Register 10011 NbrPorts 1 USB EHCI 1.00 scanning bus for devices… 2 USB Device(s) found scanning bus for storage devices… 1 Storage Device(s) found Hit any key to stop autoboot: 0 UBIFS error (pid 0): ubifs_get_sb: cannot open “ubi:fast”, error -19 Error reading superblock on volume ‘ubi:fast’! UBIFS not mounted, use ubifs mount to mount volume first! Loading file “/boot/uImage” from usb device 0:1 (usbda1) Failed to mount ext2 filesystem… ** Bad ext2 partition or disk – usb 0:1 ** Loading file “/uInitrd” from usb device 0:1 (usbda1) Failed to mount ext2 filesystem… ** Bad ext2 partition or disk – usb 0:1 ** reading /boot/uImage

    ** Unable to read “/boot/uImage” from usb 0:1 ** reading /uInitrd

    ** Unable to read “/uInitrd” from usb 0:1 ** ** Block device usb 1 not supported ** Block device usb 1 not supported

    ** Invalid boot device **

    ** Invalid boot device ** ** Block device usb 2 not supported ** Block device usb 2 not supported

    ** Invalid boot device **

    ** Invalid boot device ** ** Block device usb 3 not supported ** Block device usb 3 not supported

    ** Invalid boot device **

    ** Invalid boot device **

    Reset IDE: Bus 0: OK Bus 1: not available Device 0: Model: ST32000542AS Firm: CC95 Ser#: 5XW132TA Type: Hard Disk Supports 48-bit addressing Capacity: 1907729.0 MB = 1863.0 GB (-387938128 x 512) Loading file “/boot/uImage” from ide device 0:1 (hda1) ** ext2fs_devread() read outside partition sector -844890096 ** File not found /boot/uImage Loading file “/uInitrd” from ide device 0:1 (hda1) 4005544 bytes read UBIFS error (pid 0): ubifs_get_sb: cannot open “ubi:boot”, error -19 Error reading superblock on volume ‘ubi:boot’! UBIFS not mounted, use ubifs mount to mount volume first! reading /boot/uImage

    ** Unable to read “/boot/uImage” from ide 0:1 ** reading /uInitrd

    ** Unable to read “/uInitrd” from ide 0:1 ** ** Bad partition 1 ** ** Bad partition 1 ** No Powersaving mode 7F Error (no IRQ) dev 1 blk 0: status 0x7f ** Can’t read from device 1 **

    ** Unable to use ide 1:1 for fatload ** No Powersaving mode 7F Error (no IRQ) dev 1 blk 0: status 0x7f ** Can’t read from device 1 **

    ** Unable to use ide 1:1 for fatload ** UBIFS error (pid 0): ubifs_get_sb: cannot open “ubi:ramdisk”, error -19 Error reading superblock on volume ‘ubi:ramdisk’! UBIFS not mounted, use ubifs mount to mount volume first! Marvell>>

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  9. Hi Phillip,

    first of all thanks for this guide! It really has helped me! My GoFlexHome has worked fine for quite a long time after following ur instructions… but then somehow pacman won’t work anymore. I tried really everything to fix it but without success…

    So I decided to reflash the original firmware back to the device by using the instruction from seagate.com. Though it didn’t work, coz after a restart the green light won’t stop blinking and I could not get any access to the device.

    But though after a few restarts the green light finally stops blinking and it received the specified IP address. The problem now is that I always get the msg “connection refused” everytime I try to connect via SSH (putty).

    Do you hav any idea why? or what should I do? I found many threads in diff forums in google that also talking about hacking some stora system, but I couldn’t anything relevant for me…

    I’ll appreciate every little help!

    regards, mario

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
    • Hi Mario! I hope you have solved your issues by now. After I found my GoFlex Home again recently, I plugged it in and updated all packages (~ 210). Afterwards I could not reach the device anymore (my DHCP server reported that it requested and received an IP address) but no ping or ssh attempt worked. I tried to change some configuration files by connecting the hard disk to an Ubuntu based Linux computer. Again, this didn’t bring me back my GoFlex Home. It started and the front LED was green (constantly) but no connection possible.

      So in the end, I connected it to my Linux computer (again), was copying all configuration files to a safe location, removing all files on the Arch Linux partition and downloaded the latest system package from http://archlinuxarm.org/ and unpacked it on the partition. This way I could get it back to work. Regards, Philipp

      VN:F [1.9.22_1171]
      Rating: 0 (from 0 votes)
  10. Hi,

    I tried to install it using http://archlinuxarm.org/platforms/armv5/seagate-goflex-home But I got stuck at the first reboot as I can’t connect to it with “ssh root_hipserv2_seagateplug_MYSERIALNUMBER@192.168.x.x” or with “ssh root@192.168.x.x”. I also can’t ping to it.

    ping: sendto: No route to host ping: sendto: Host is down Request timeout for icmp_seq 0

    I changed my keygenerator… but that didn’t help either. (I’m using mac)

    I checked my router if the ip was changed but the mac adress or the right ip doesn’t even come up at my router.

    I tried to find out netconsole but when I try that it doesn’t return anything.

    What did I do wrong or What went wrong? as the top light is steady after startup, but there is no green light under it.

    And when i put the latest ArchLinuxARM on a fat32 usbstick and plug it in my goFlex Home, will it boot up from there automaticly with ssh installed so i can connect to it and see what went wrong?

    Otherwise i’m going to try to get the original firmware back from http://support.goflexhome.hipserv.com/en/reflash/index.html

    Thanx in advance for any help!

    Greetings.

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  11. [...] Firefly Media Server – mt-daapd The configuration file is /etc/mt-daapd.conf (no UCI config file). Enable and start it using /etc/init.d/mt-daapd enable && /etc/init.d/mt-daapd start. I wrote more about the configuration options on this blog post. [...]

  12. [...] USB sound card that I bought when my older M-Audio Transit USB wasn’t working well on my Seagate GoFlex Home. I’m also planning to use on my Buffalo WZR-HP-AG300H WiFi router. This blog post documents [...]

  13. I have managed to flash my GoFlex successfully and have everything working as expected.

    My issue is that I have multiple hard drives (the current one being used is 2TB, but also have a 3TB and a 4TB) and I want to install ArchLinux so that I have the same config on all of them.

    I am unsure as to the best way to achieve this – can I clone the 2TB drives and extend the sda2 partition? Do I need to modify the UBIT environment?

    Thanks for your great article and appreciate any help you can provide!

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
    • Hi Jacob,

      yes, you can clone the 2TB hard disk to the other disks and then extend the partition. This can be done best by attaching them to a desktop computer, using the dd command to clone the content and gparted to extend the partition size afterwards. You don’t need to modify UBIT.

      VN:F [1.9.22_1171]
      Rating: 0 (from 0 votes)
      • Hi Phillip,

        As I am moving from a 2TB to a 3TB do I need to change the partition structure to Hybrid GPT?

        Thanks for your prompt help!

        Cheers,

        Jacob

        VA:F [1.9.22_1171]
        Rating: 0 (from 0 votes)
  14. My GFH is gone after ubit start only. i was acsently remove power adapter. Now dock green flash blinking. what i need to do?

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  15. Now i can connect SSH. but ping to google.com is “host unkwon”. how to resolve?

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  16. the official Seagate forums have a shocking response to a request that NFS be baked into next consumer NAS:

    http://forums.seagate.com/t5/FreeAgent-Theater-and-GoFlexTV/NFSv4/m-p/182048

    [silence]

    a “response” promised in reply to request for esatap instead of USB

    http://forums.seagate.com/t5/FreeAgent-Theater-and-GoFlexTV/eSataP/m-p/182046

    esatap: ONE port providing optionS of USB3 or eSata. A minuscule design cost for massive consumer convenience to sheeple and savvy alike: no wrong insertion into ports!

    when will more USB storage gizmos upgrade to eSataP???

    Loved your NFS hackupgrade :) next stop sabnzbd+ ? [licensed content]

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  17. Have you tried owncloud on this device? It works for me, but the sync speed is really slow. Like “300MB overnight” slow. I had to create a swap partition (128Mb is not enough for MySql service to start) and increase the PHP file size limit to 30GB. Other than that, I followed the instructions in your website and other resources to the word.

    I would be great to have a dropbox-like cloud solution at home, with almost no size restriction. Especially when you have openVPN for secure access.

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  18. [...] Philipp Klaus’ ArchLinux on GoFlex instructions [...]

  19. Hi, Phillip… excellent tutorial! but I have one question – is any chance to install ArchLinuxARMv5 to VirtualBox? I’m searching some bootable iso of this system, or some advices how to directly install this to VirtualBox: http://archlinuxarm.org/os/ArchLinuxARM-armv5te-latest.tar.gz or this http://support.goflexhome.hipserv.com/en/reflash/index.html

    Thank you for reply and have nice day

    Dominik

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  20. Hallo, kann man die Anleitung auch auf deutsch haben? Mein Englisch ist nicht so gut und ich möchte keine Fehler machen. Ist zur Installation zwingend ein Linux-System erforderlich oder geht das auch mit einem Windows Rechner?

    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
    • Eine recht gute deutsche Anleitung (für das sehr ähnliche Gerät Seagate FreeAgent DockStar) gibt es hier: linux.bplaced.net. Das System mit einem Windows Rechner herzurichten könnte etwas frickelig werden, vielleicht geht es auch gar nicht. Viele Grüße Philipp

      VN:F [1.9.22_1171]
      Rating: 0 (from 0 votes)

 Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>