Ubuntu Server 13.04 Quiet Giant for ODROID-X2 (20140101)

Locked
User avatar
robroy
Posts: 3401
Joined: Mon Feb 25, 2013 2:29 am
languages_spoken: English
ODROIDs: Q2, X, X2, U2, U3, XU-E, XU3, XU4, C1, C1+, C2
Location: San Francisco, California
Contact:

Ubuntu Server 13.04 Quiet Giant for ODROID-X2 (20140101)

Unread post by robroy » Sat Sep 21, 2013 8:06 am

I created a Linaro Ubuntu Server 13.04 Raring Ringtail image, forked from the official Hard Kernel release, with a core suite of applications for an Internet server.

Download the image here:
http://oph.mdrjr.net/robroyhall/images/ ... 101.img.xz

European mirror by @traxo:
http://odroid.txmonitor.de/

Want to upgrade your existing Quiet Giant image?
Kernel updates: http://builder.mdrjr.net/tools/kernel-update.sh

Username: root
Password: odroid

Username: odroid
Password: odroid

Servers: Mail, DNS, Tomcat, MySQL, Apache 2, JRuby, PHP 5, FTP, Samba, Open SSH and Minecraft/Spigot.

If you enjoy my contributions to the Hard Kernel community, please consider donating an amount of your choice via the link in my signature.

Customizations left for you upon burning the image to your card:
  • 1. Resize the "rootfs" partition to fit your SD card. This is best done on another Linux system using the GParted utility.
    2. Remove unused servers with tasksel to free up memory and processor cycles.
    3. Change your server time zone from UTC using "dpkg-reconfigure tzdata".
    4. Change the MySQL admin password which defaults to blank.
Improvements and upgrades:
  • 1. To overclock to 1.92GHz, type "sudo gedit /etc/rc.local" in Terminal and remove the "#" from the beginning of the line that starts with "echo 1920000".
    2. All upgrades and updates have been run using aptitude and apt-get.
    3. All orphaned and obsolete packages have been purged, including the original kernel.
Features in this release:
  • Official HK kernel 3.8.13.11 (commit 4d40140b44917be7fa344cc8242b8ed0f3e89e97)
    Oracle JDK8 September 2013
    Blackbox Desktop Environment
    Headless server (SSH, USB-UART serial output, or HDMI desktop)
    Apache 2 web server running JRuby and PHP 5
    Samba shares at /var/www/, /var/lib/tomcat7/webapps/ROOT, and /home/odroid/Documents for sandbox website development
    MySQL server integrated with Spigot, Tomcat and Apache
    Spigot 1.6.4 server with Factions, Factions Plus, Hunger Games, PVP Arena, Kit PVP, World Edit, Vault, Essentials and more
    Installable on 8GB eMMC
Notes:
  • All servers are started on boot except for Spigot.

    Approximately 350MB of RAM is used when all 8 servers are running, leaving 1.65GB free for server use.

    Use "shutdown -h now" when powering down to avoid single-user maintenance mode, ensuring that the rootfs unmounts cleanly.

    When the image is booted without the wired LAN plugged in, the clock time may become out-of-sync, unless you are using a clock battery. In Linaro, this time difference causes the root file system to be mounted as read-only. If this happens, type "fsck /" when logged in as root, then reboot with the LAN properly attached. This will unlock the file system and re-synchronize the clock with Internet time via NTP.

    Swap is enabled in the kernel, which extends memory beyond 2GB (more here: http://www.cyberciti.biz/faq/linux-add- ... ile-howto/)

    Apache is available at http://127.0.0.1:80, and Tomcat is at http://127.0.0.1:8080.

    Follow this guide to use Nginx instead of Apache after uninstalling Apache: http://forum.odroid.com/viewtopic.php?f=52&t=167

    Spigot version 1.6.4 is installed in /home/odroid/Public/, and may be started with:

    Code: Select all

    cd ~/Public/spigot
    ./spigot.sh
    
    Image
Last edited by robroy on Fri Jan 03, 2014 2:10 am, edited 22 times in total.
Rob Roy, Editor-in-Chief of ODROID Magazine (submit an article | make a donation)

User avatar
odroid
Site Admin
Posts: 30028
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Contact:

Re: Ubuntu Server 13.05 Quiet Giant for ODROID-X2 (20130920)

Unread post by odroid » Sat Sep 21, 2013 2:09 pm

I love your naming sense.. Quiet Giant! :o

User avatar
robroy
Posts: 3401
Joined: Mon Feb 25, 2013 2:29 am
languages_spoken: English
ODROIDs: Q2, X, X2, U2, U3, XU-E, XU3, XU4, C1, C1+, C2
Location: San Francisco, California
Contact:

Re: Ubuntu Server 13.05 Quiet Giant for ODROID-X2 (20130920)

Unread post by robroy » Tue Sep 24, 2013 9:38 am

odroid wrote:I love your naming sense.. Quiet Giant! :o
:D :D :D

Naming the images is the most fun part of building them 8-)
Rob Roy, Editor-in-Chief of ODROID Magazine (submit an article | make a donation)

User avatar
robroy
Posts: 3401
Joined: Mon Feb 25, 2013 2:29 am
languages_spoken: English
ODROIDs: Q2, X, X2, U2, U3, XU-E, XU3, XU4, C1, C1+, C2
Location: San Francisco, California
Contact:

Re: Ubuntu Server 13.05 Quiet Giant for ODROID-X2 (20131004)

Unread post by robroy » Sat Oct 05, 2013 3:30 am

New features in this release:
  • Upgraded kernel to 3.8.13.10
Enjoy!
Rob Roy, Editor-in-Chief of ODROID Magazine (submit an article | make a donation)

User avatar
robroy
Posts: 3401
Joined: Mon Feb 25, 2013 2:29 am
languages_spoken: English
ODROIDs: Q2, X, X2, U2, U3, XU-E, XU3, XU4, C1, C1+, C2
Location: San Francisco, California
Contact:

Re: Ubuntu Server 13.05 Quiet Giant for ODROID-X2 (20131030)

Unread post by robroy » Mon Nov 04, 2013 12:16 am

New features in this release: Enjoy !

Want to upgrade your existing Quiet Giant image ?

1. Add the file /etc/e2fsck.conf with the following contents:

Code: Select all

[problems]

# Superblock last mount time is in the future (PR_0_FUTURE_SB_LAST_MOUNT).
0x000031 = {
    preen_ok = true
    preen_nomessage = true
}

# Superblock last write time is in the future (PR_0_FUTURE_SB_LAST_WRITE).
0x000032 = {
    preen_ok = true
    preen_nomessage = true
}
Rob Roy, Editor-in-Chief of ODROID Magazine (submit an article | make a donation)

LiquidAcid
Posts: 1091
Joined: Fri Oct 11, 2013 11:07 pm
languages_spoken: english
ODROIDs: X2
Contact:

Re: Ubuntu Server 13.05 Quiet Giant for ODROID-X2 (20131030)

Unread post by LiquidAcid » Mon Nov 04, 2013 1:31 am

This is a bad idea, since software should be able to depend on a monotonically increasing clock. If the clock can jump back and forth in time, then this can have all sorts of weird side-effects. It's better to use something similar to openrc's swclock, together with ntp/chrony.

User avatar
robroy
Posts: 3401
Joined: Mon Feb 25, 2013 2:29 am
languages_spoken: English
ODROIDs: Q2, X, X2, U2, U3, XU-E, XU3, XU4, C1, C1+, C2
Location: San Francisco, California
Contact:

Re: Ubuntu Server 13.05 Quiet Giant for ODROID-X2 (20131030)

Unread post by robroy » Mon Nov 04, 2013 1:53 am

LiquidAcid wrote:This is a bad idea,
Thanks :?
If the clock can jump back and forth in time, then this can have all sorts of weird side-effects.
In the previous releases as well as the stock Hard Kernel distro, if you didn't have a backup battery in your Odroid, the file system would lock up as read only because the clock loses its time, making the entire image unusable. It is a common problem with the Linaro builds. Ubuntu just fixes the problem with fsck and moves on.
It's better to use something similar to openrc's swclock, together with ntp/chrony.
Would you mind posting a how-to for the alternative that you're proposing, along with a boot log verifying that your solution works?
Rob Roy, Editor-in-Chief of ODROID Magazine (submit an article | make a donation)

LiquidAcid
Posts: 1091
Joined: Fri Oct 11, 2013 11:07 pm
languages_spoken: english
ODROIDs: X2
Contact:

Re: Ubuntu Server 13.05 Quiet Giant for ODROID-X2 (20131030)

Unread post by LiquidAcid » Mon Nov 04, 2013 2:45 am

robroyhall wrote:In the previous releases as well as the stock Hard Kernel distro, if you didn't have a backup battery in your Odroid, the file system would lock up as read only because the clock loses its time, making the entire image unusable.
Correct me if I'm wrong, but this clock slew problems just result in the root fs not being remounted rw, so it stays read-only. This of course let's most of init fail, but our trusty serial console should still works. But you probably know this already.
robroyhall wrote:It is a common problem with the Linaro builds. Ubuntu just fixes the problem with fsck and moves on.
And because Ubuntu "fixes" it in such a way, it's a good fix? I don't think so. Even e2fsck points out that software depends on time not going backwards. Forcing fsck to continue is like to paper over the real issue.
robroyhall wrote:Would you mind posting a how-to for the alternative that you're proposing, along with a boot log verifying that your solution works?
I don't use Ubuntu, nor do I know how Upstart script work. I can however refer you to openrc's swclock. If you don't want to implement this in C, you can probably get away with just using date, stat and touch.

Let the Upstart script touch a file (openrc uses /lib/rc/cache/shutdowntime) on shutdown. On start you stat the file and set the time with date. Maybe you can also sync to the RTC with hwclock at this point. This should all happen before fsck, ntp, etc. starts.

I have such a configuration running on the X2 since some weeks. I just have to let chrony makestep from time to time (no pun intended), since there is limit with how fast it can accelerate the clock. Hope this helps.

LiquidAcid
Posts: 1091
Joined: Fri Oct 11, 2013 11:07 pm
languages_spoken: english
ODROIDs: X2
Contact:

Re: Ubuntu Server 13.04 Quiet Giant for ODROID-X2 (20131030)

Unread post by LiquidAcid » Mon Nov 04, 2013 2:52 am

Largely unrelated, but on Gentoo you just replace the hwclock service by swclock, as described e.g. here. The only modification I use is this additional runscript (also in boot level):

Code: Select all

#!/sbin/runscript

description="Update the system RTC"

depend() {
        after swclock
        before *
}

start() {
        ebegin "Updating system RTC"
        hwclock --utc --systohc --noadjfile
        eend $?
}
This is the chrony.conf I use:

Code: Select all

server 0.de.pool.ntp.org
server 1.de.pool.ntp.org
server 2.de.pool.ntp.org

driftfile /var/lib/chrony/drift
keyfile /etc/chrony/chrony.keys
commandkey 1

dumponexit
dumpdir /var/lib/chrony

logdir /var/log/chrony
log measurements statistics tracking rtc
cmdallow 127.0.0.1

rtcsync
rtconutc
rtcdevice /dev/rtc
Pretty straight forward, I think.

User avatar
robroy
Posts: 3401
Joined: Mon Feb 25, 2013 2:29 am
languages_spoken: English
ODROIDs: Q2, X, X2, U2, U3, XU-E, XU3, XU4, C1, C1+, C2
Location: San Francisco, California
Contact:

Re: Ubuntu Server 13.04 Quiet Giant for ODROID-X2 (20131030)

Unread post by robroy » Mon Nov 04, 2013 7:18 am

I can however refer you to openrc's swclock. If you don't want to implement this in C, you can probably get away with just using date, stat and touch.
Thank you for the suggestion!

If anyone has a chance to implement this before I do, please post feedback.
Rob Roy, Editor-in-Chief of ODROID Magazine (submit an article | make a donation)

User avatar
robroy
Posts: 3401
Joined: Mon Feb 25, 2013 2:29 am
languages_spoken: English
ODROIDs: Q2, X, X2, U2, U3, XU-E, XU3, XU4, C1, C1+, C2
Location: San Francisco, California
Contact:

Re: Ubuntu Server 13.04 Quiet Giant for ODROID-X2 (20140101)

Unread post by robroy » Fri Jan 03, 2014 2:50 am

New features:
  • Restored ~/.bashrc, ~/.bash_logout and ~/.profile from /etc/skel/
    Updated /etc/default/rcS to include FSCKFIX=yes
Enjoy!
Rob Roy, Editor-in-Chief of ODROID Magazine (submit an article | make a donation)

Locked

Return to “Ubuntu”

Who is online

Users browsing this forum: No registered users and 1 guest