Forum
[HOW-TO] Installing XBIAN directly on RASPBIAN IMG - Printable Version

+- Forum (http://forum.xbian.org)
+-- Forum: Software (/forum-6.html)
+--- Forum: Installation (/forum-16.html)
+--- Thread: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG (/thread-1850.html)

Pages: 1 2 3 4 5 6 7 8


[HOW-TO] Installing XBIAN directly on RASPBIAN IMG - mk01 - 6th Dec, 2013 05:59 AM

The current degree of XBian code base integration with it's host (debian based linux distributions) will allow you in a few minutes transform existing original untouched Raspbian image into XBian media station at such extend that you mix up your SD card by accident very fast - just to realize that it doesn't matter which way your XBian was created (if from debootrstraped minimal image as online installation hosted on another machine, or by utilizing older installation or even by just installing the same distribution XBian images.

Just to really assure the user::: by installing XBian packages Raspbian will still stay Raspbian, all configuration files will be kept, no configs will get overwritten in an improper way, configuration stays the same. Only to small details, if you configured your Raspbian as fully capable universal pc (for browsing net, writing documents, tracking family agenda with shared collaboration simply anything after XBian reboots you won't feel the difference.

INSTALLATION STEPS ONE BY ONE:

1)
Code:
cd /tmp
sudo -s
wget http://apt.xbian.org/pool/stable/main/x/xbian-package-repo/xbian-package-repo_20150205-6_armhf.deb
dpkg -i xbian-package-repo_*_armhf.deb

This will install our repositories. When that's done hit:
Code:
apt-get clean; apt-get update

As first we install same base files relevant to new user xbian.
2)
Code:
sudo apt-get install xbian-package-xbianhome


this will unpack /home/xbian, register user (by default password "raspberry"), put into relevant system groups and other steps.

3)
On Raspberry Pi 1:
Code:
sudo apt-get install xbian-package-kernel
On Raspberry Pi 2:
Code:
sudo apt-get install linux-image-bcm2836

This will deliver kernel and supporting tools. at this stage we need to reboot. XBian needs to update system partition and adapt some system configs as /etc/fstab. if apt-get process from installing xbian-package-kernel finishes, XBian already updated /boot/cmdline.txt and /boot/config.txt to be able to perform this maintenance tasks upon reboot. so we just run "reboot"

4) after RPI starts booting again, resize & convert will take place. on clean Raspbian image it can take 10-15 minut (but even hours on BIG hard drives with lot of data). after success - /etc/fstab will be adapted automatically again RPI should start rebooting and booting back to Raspbian.

6) as the system boots again (we have our XBian user, XBian's home dir, filesystem is ok…). we just need to install the less interesting packages as XBMC itself and all the tools helping using and configuring things we like.
Code:
apt-get install xbian-update xbian-package-rasp-switching

xbian-update will trigger installation of all XBian packages from base system.

after next (and last) re-boot beside seeing XBIAN splash screen, your system will still be booting as you configured early during Raspbian setup. XBMC can be started with "start XBMC", Raspbian X desktop with "service lightdm start".

if you Raspbian setup used to boot into X with PI user automatically, you can keep this and indeed start / load XBMC quick and easy way - even jumping back and forth between XBMC and you X Desktop. We can click "Logout", put "xbian" as user to log in and XBMC starts. If you quit XBMC, X will come again. No reboots needed.
Both X and XBMC can be managed now from xbian-config tool (from SSH or even XBMC). There is how you RPI will boot if you select what service for autostart:


auto LXDE, auto XBMC => LXDE loads desktop with user PI. logout/login as user xbian delivers XBMC in few seconds. XBMC exit is return to LXDE.

manual LXDE, auto XBMC => XBian like experience. System boot directly into XBMC, you can exit XBMC to console, or reboot or shutdown directly from XBMC menu.

manual LXDE, XBMC => normal TTY terminals asking for password - possibility to start on or the other through xbmc or lightdm jobs respectively.

==========
Just for complete info, this XBian installation path was tested on Raspbian image based on Wheezy 7.2, but also on debootstreped minimal (140mb) image of Jessie (next Debian / Raspbian relese to come).


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - coloxim - 6th Dec, 2013 07:46 AM

Wow... I've to read it again for understand better.. but I can say thank you so much!!

It help much!!!

(6th Dec, 2013 05:59 AM)mk01 Wrote:  ".

In the next day we will issue some updates to clean a bit - or optimize if you wan't - Raspbian standard setup and workflows to speed it a bit up. But already with this default setup there is not much difference between Beta2 created the XBian usual way and this one.

This only puts a little more weight on our humble recommendation that let's nobody waste time with clean flashes & reconfigurations until VERY VERY needed as last resort. As otherwise we do this for you within all the complex code in XBian packages doing the job for your. RPI should be there for us to enjoy, not the other way around.

Enjoy.

You can make a optimize raspbian setup?

If we want? Of course..
Please..

Thanks for your work!!!


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - mk01 - 6th Dec, 2013 11:17 AM

(6th Dec, 2013 07:46 AM)coloxim Wrote:  You can make a optimize raspbian setup?

If we want? Of course..

just to put this right, this doesn't mean there is a program running on the background counting how much stars is on in the sky taking 100mb and 50% of cpu time.

with just downloaded RASPBIAN IMG (exactly this one :
Image 2013-09-25-wheezy-raspbian.zip
Torrent 2013-09-25-wheezy-raspbian.zip.torrent
SHA-1 Checksum 99e6b5e6b8cfbf66e34437a74022fcf9744ccb1d
Default login pi / raspberry
Description A Debian wheezy port, optimised for the Raspberry Pi
Release Date 2013-09-25
Version wheezy
Kernel 3.6)

without any manual touch / edit / remove action (just by updating XBian pac
kages if was needed and then reinstalling directly to the IMG again), after finishing with XBian debs and reboot, XBMC booted in 31s on same RPI with same config.txt (XBian Beta2 clean flash 29-30s).
GUI, addons etc were running SUBJECTIVELY the same way.

of course you have there some silly things like:
- complete cross compile toolchain for cross platform development - who the hell is willing to die in the front of his own RPI on exhaustion waiting one week for "hello world" to compiled for architecture of os supa-dupa supercomputer located in CHINA? I lnow who, … only the one guy who runs it. So we normal people remove it (it takes 100M)
- or whose idea was to make SAMBA 2 Windows Domain Services to be started and working by default if most of the deployments hardly runs external hard drive as (in the means of being attached to other equipment.

so of course i'm doing to implement this as part of clean up code , but this is like dead weight, it is not taking live cycles from you. and the ugly GENERALLY needed stuff (which for REAL NOBODY ever used) was already cleaned up.

otherwise XBian would not be XBian as we do this all the time - we don't take the system manually apart later.

If you are interested go for it, you won't feel difference, you get update later as any other XBian user (because it will be actually XBian with only one difference that you already have working ALSA/PULSEAUDIO, XWINDOWS with some kind of Office application for sure, nice Browser and it works already as expected without recompiling FB Xorg system, looking for patches, showing correct local characters (triangular shaped objects instead) (ok, I admit it is not that bad as 10 years ago but still going from minimal install to a fully working consolidated system was nightmare to me). why to bother if it goes the easy way. it was first time I have seen raspbian running RPI - I mean really look into the disto. And be used to here the usual stuff how much shit it is even for non-commercials and developing world - only positive surprise. Any commercial company from direction ASIA/PACIFIC would be so much successful if they only would be able to deliver such consolidated and cheap product.

don't feel like you need to wait for better and more optimized version. in reality it is a dream nobody will ever get to. like dog trying to catch own tail.

To my surprise there were NO conflicts (as they are for some users of older XBian version) - I as expecting more packages - more issues I we could catch in advance but no.

Next days we plan to put updates containing boot manager with maybe some easy to use clever helper tools to make consultation to one card for more systems they like as easy as for instance the cloner function. Looks like the popular NOOBS or BerryBoot in use and working but are limiting the user experience like for instance no updates etc, or making the system installation a nightmare for non experienced users (for unsupported systems). Definitely during first release but I expect this to work as easy and without limitations as FULL BOOT LOADERS used on PC or better nothing. Because then a hardly enjoyable experience is becoming bad experience and frustration.

In any case if you check this one anytime soon, report instantly back. I going to make the first post more stricture to better focus on the technical steps. After we get a clear picture, we can prepare an installer.


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - Killerbee - 6th Dec, 2013 07:35 PM

@mk01

Man I can't catch up with you Smile

This weekend I have to create an img using debootstap, (I really want to learn this) and I have to test this "How-to".
Besides that I have to translate xbian-config* packages and play with squeelize incombination with pulse-audio.

Man is Xbian your core business?

KB


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - coloxim - 7th Dec, 2013 05:26 AM

Alter I put SD in windows PC, edit cmdline And reboot, my raspberry doesn't boot...
I can see only black screen...


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - Scooby-2 - 7th Dec, 2013 05:34 AM

I followed the instructions but only got as far as step 2 - this fails with the following:

Quote:root@pi:~# apt-get install xbian-package-xbianhome
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
xbian-package-xbianhome
0 upgraded, 1 newly installed, 0 to remove and 116 not upgraded.
Need to get 2490 kB of archives.
After this operation, 4908 kB of additional disk space will be used.
Get:1 http://xbian.brantje.com/ staging/main xbian-package-xbianhome armhf 1.0.0-1 [2490 kB]
Fetched 2490 kB in 4s (560 kB/s)
Selecting previously unselected package xbian-package-xbianhome.
(Reading database ... 31281 files and directories currently installed.)
Unpacking xbian-package-xbianhome (from .../xbian-package-xbianhome_1.0.0-1_armhf.deb) ...
Setting up xbian-package-xbianhome (1.0.0-1) ...
dpkg: error processing xbian-package-xbianhome (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
xbian-package-xbianhome
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@pi:~#

I rebooted and tried again:

Quote:root@pi:~# apt-get install xbian-package-xbianhome
Reading package lists... Done
Building dependency tree
Reading state information... Done
xbian-package-xbianhome is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 116 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue [Y/n]? y
Setting up xbian-package-xbianhome (1.0.0-1) ...
groupadd: group 'input' already exists
dpkg: error processing xbian-package-xbianhome (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
xbian-package-xbianhome
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@pi:~#

I don't know how to tell what's wrong. Huh Anyone have any ideas?

Edit: FYI:
Quote:root@pi:~# uname -a
Linux raspbmc 3.10.17 #2 PREEMPT Mon Nov 4 03:32:53 UTC 2013 armv6l GNU/Linux
root@pi:~# lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 7.0 (wheezy)
Release: 7.0
Codename: wheezy
root@pi:~#



R: RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - coloxim - 7th Dec, 2013 05:43 AM

(7th Dec, 2013 05:34 AM)Scooby-2 Wrote:  I followed the instructions but only got as far as step 2 - this fails with the following:

Quote:root@pi:~# apt-get install xbian-package-xbianhome
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
xbian-package-xbianhome
0 upgraded, 1 newly installed, 0 to remove and 116 not upgraded.
Need to get 2490 kB of archives.
After this operation, 4908 kB of additional disk space will be used.
Get:1 http://xbian.brantje.com/ staging/main xbian-package-xbianhome armhf 1.0.0-1 [2490 kB]
Fetched 2490 kB in 4s (560 kB/s)
Selecting previously unselected package xbian-package-xbianhome.
(Reading database ... 31281 files and directories currently installed.)
Unpacking xbian-package-xbianhome (from .../xbian-package-xbianhome_1.0.0-1_armhf.deb) ...
Setting up xbian-package-xbianhome (1.0.0-1) ...
dpkg: error processing xbian-package-xbianhome (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
xbian-package-xbianhome
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@pi:~#

I rebooted and tried again:

Quote:root@pi:~# apt-get install xbian-package-xbianhome
Reading package lists... Done
Building dependency tree
Reading state information... Done
xbian-package-xbianhome is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 116 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue [Y/n]? y
Setting up xbian-package-xbianhome (1.0.0-1) ...
groupadd: group 'input' already exists
dpkg: error processing xbian-package-xbianhome (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
xbian-package-xbianhome
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@pi:~#

I don't know how to tell what's wrong. Huh Anyone have any ideas?

Edit: FYI:
Quote:root@pi:~# uname -a
Linux raspbmc 3.10.17 #2 PREEMPT Mon Nov 4 03:32:53 UTC 2013 armv6l GNU/Linux
root@pi:~# lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 7.0 (wheezy)
Release: 7.0
Codename: wheezy
root@pi:~#

Did you edit source list?
Anyway my rasp doesn't boot...
;(


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - Scooby-2 - 7th Dec, 2013 05:54 AM

Quote:Did you edit source list?
Anyway my rasp doesn't boot...
;(

Yes, then I ran apt-get update as root....


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - mk01 - 7th Dec, 2013 06:07 AM

(7th Dec, 2013 05:26 AM)coloxim Wrote:  Alter I put SD in windows PC, edit cmdline And reboot, my raspberry doesn't boot...
I can see only black screen...

after you installed xbian-package-kernel successfully
and edited your cmdline.txt to look like this?

Code:
dwc_otg.fiq_fix_enable=1 sdhci-bcm2708.sync_after_dma=0 dwc_otg.lpm_enable=0 console=tty2 root=/dev/mmcblk0p2 rootfstype=btrfs rootwait logo.nologo quiet loglevel=0 splash partswap

?


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - coloxim - 7th Dec, 2013 06:26 AM

(7th Dec, 2013 06:07 AM)mk01 Wrote:  
(7th Dec, 2013 05:26 AM)coloxim Wrote:  Alter I put SD in windows PC, edit cmdline And reboot, my raspberry doesn't boot...
I can see only black screen...

after you installed xbian-package-kernel successfully
and edited your cmdline.txt to look like this?

Code:
dwc_otg.fiq_fix_enable=1 sdhci-bcm2708.sync_after_dma=0 dwc_otg.lpm_enable=0 console=tty2 root=/dev/mmcblk0p2 rootfstype=btrfs rootwait logo.nologo quiet loglevel=0 splash partswap

?


no really the same...

Code:
dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p2 rootflags=subvol=root/@,autodefrag,compress=lzo rootfstype=btrfs partswap elevator=deadline rootwait



RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - mk01 - 7th Dec, 2013 07:16 AM

@coloxim

until you pass step 2 and 3, nothing relevant to boot process is changed. the error just mean input group already exists. I created

kernel 3.10.17 is raspbian. so there was nothing changed XBian packages yet.

I corrected that "input group already exists" and set the the process to change rootfstype to brtrfs to ask for conversion and also after successful conversion to change rootflags= parameter to be compatible with btrfs and FS layout. so the manual step of manipulating SD card should not be needed anymore.

(7th Dec, 2013 06:26 AM)coloxim Wrote:  no really the same...

Code:
dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p2 rootflags=subvol=root/@,autodefrag,compress=lzo rootfstype=btrfs partswap elevator=deadline rootwait

this difference is ok, important are the rootflags and rootfstype …

just wandering, why it doesn't boot. ach maybe one idea. there should be line
Code:
initramfs initramfs.gz  0x00a00000

in /boot/cmdline.txt .. without this root partition can't be processed in any way as kernel will try to boot directly by mounting it. but it should be set during the process kernel is unpacking and creating initramfs.gz file.


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - coloxim - 7th Dec, 2013 07:22 AM

I've insert that line?


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - mk01 - 7th Dec, 2013 07:25 AM

@coloxim

there is zipped content of valid kernel + initrmafs + firmware loader files in http://xbian.brantje.com/others/boot20131206.zip
(just in case your got damaged in any way?)

if you will unpack it to our /boot on windows or linux, don't take cmdline.txt and config.txt files. these will not work until all packages are installed.

(7th Dec, 2013 07:22 AM)coloxim Wrote:  I've insert that line?

it should be there yes. if you don't have it. it is put there at the end of kernel and initramfs installation to be able to convert rootfs.

but if it is missing can mean some writes failed (so maybe including kernel or initramfs.gz file). this would explain the blank screen.

but don;t be afraid. no boot looks scary but it is not big problem.


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - coloxim - 7th Dec, 2013 07:33 AM

(7th Dec, 2013 07:25 AM)mk01 Wrote:  @coloxim

there is zipped content of valid kernel + initrmafs + firmware loader files in http://xbian.brantje.com/others/boot20131206.zip
(just in case your got damaged in any way?)

if you will unpack it to our /boot on windows or linux, don't take cmdline.txt and config.txt files. these will not work until all packages are installed.

(7th Dec, 2013 07:22 AM)coloxim Wrote:  I've insert that line?

it should be there yes. if you don't have it. it is put there at the end of kernel and initramfs installation to be able to convert rootfs.

but if it is missing can mean some writes failed (so maybe including kernel or initramfs.gz file). this would explain the blank screen.

but don;t be afraid. no boot looks scary but it is not big problem.

i've to put that line and the unzip pkg without cmdlin and config? right?


RE: [HOW-TO] Installing XBIAN directly on RASPBIAN IMG - mk01 - 7th Dec, 2013 07:52 AM

oh sorry I always forget the raspbian is never using so it is new for you.

it should be in first line then following other std parameters like this
Code:
initramfs initramfs.gz  0x00a00000
#hdmi_mode=2
initial_turbo=1
gpu_mem_256=128
gpu_mem_512=384
decode_MPG2=
arm_freq=840
core_freq=275
sdram_freq=400
over_voltage=0
hdmi_force_hotplug=1
hdmi_ignore_cec_init=1
disable_splash=1