Mister Parsnips
Posts: 18
Joined: Wed Jul 25, 2012 5:08 pm

Change from XBMC to Standard Desktop from within Linux

Mon Apr 04, 2016 8:31 pm

Greetings all!

I am not certain how even to ask this question, so be gracious if I do not word it properly.

I have an original Pi that is running a prepackaged install of XBMC, used for media streaming. I want to move that media streamer on a new Pi 3 that is arriving tomorrow, and would like to use this older, slower Pi for Pi-Hole DNS.

Here's the problem:

The old Pi became damaged through heavy use, and the SD card was not making good contact with the motherboard. Eventually, I had to choose between throwing it away, and doing a radical repair. I ended breaking open the SD card, and soldering the guts of it directly to the Pi motherboard. Thus, I cannot flash that SD card in my Winders machine with a new Pi OS distribution.

My question is, whether or not it is possible to get a standard Pi desktop environment on this hard-soldered SD card while removing the XBMC, so I can turn this older Pi into the Pi-Hole DNS box. If so, can someone outline the steps to do this in an easy to follow manner?

Thanks in advance!

- damon

mathboy4life
Posts: 197
Joined: Fri Jan 08, 2016 7:29 pm

Re: Change from XBMC to Standard Desktop from within Linux

Tue Apr 05, 2016 2:00 am

Not possible since you will not be able to flash Raspbian on the older sd card. So you're stuck with xbmc on the old PI.

User avatar
DougieLawson
Posts: 36578
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Change from XBMC to Standard Desktop from within Linux

Tue Apr 05, 2016 9:04 am

Mister Parsnips wrote:
My question is, whether or not it is possible to get a standard Pi desktop environment on this hard-soldered SD card while removing the XBMC, so I can turn this older Pi into the Pi-Hole DNS box. If so, can someone outline the steps to do this in an easy to follow manner?
Get a USB stick that's at least 16GB in size. Build a root filesystem on there (you could simply dd it from your soldered in SDCard). Update the /boot partition on the soldered in card so that the rootfs is on the USB device

Code: Select all

[email protected] ~ # cat /boot/cmdline.txt
dwc_otg.lpm_enable=0 console=tty1 root=UUID=2ebfb7f2-0c0b-4de2-964c-8fe9b20aacee rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait rootdelay=5
[email protected] ~ #

Code: Select all

[email protected] ~ # cat /etc/fstab
proc            /proc           proc    defaults          0       0
/dev/mmcblk0p1  /boot           vfat    defaults          0       2
UUID=2ebfb7f2-0c0b-4de2-964c-8fe9b20aacee /     ext4    defaults,noatime       0 1
#/dev/mmcblk0p2  /               ext4    defaults,noatime  0       1
# a swapfile is not a swap partition, no line here
#   use  dphys-swapfile swap[on|off]  for that
[email protected] ~ #
your UUID will be different - /dev/sda is USB drive on my B+

Code: Select all

[email protected] ~ # blkid
/dev/mmcblk0p1: SEC_TYPE="msdos" LABEL="boot" UUID="140A-14B7" TYPE="vfat" PARTUUID="0009bf4f-01"
/dev/mmcblk0p2: UUID="f24a4949-f4b2-4cad-a780-a138695079ec" TYPE="ext4" PARTUUID="0009bf4f-02"
/dev/sda1: UUID="2ebfb7f2-0c0b-4de2-964c-8fe9b20aacee" TYPE="ext2" PARTUUID="2f3846c8-01"
/dev/mmcblk0: PTUUID="0009bf4f" PTTYPE="dos"
[email protected] ~ #
This will copy the root fs to the USB device

Code: Select all

dd if=/dev/mmcblk0p2 of=/dev/sda1 bs=40M
Boot the system and make sure it's OK (once you've updated /boot/cmdline.txt you've got to be 100% sure it's right as that's a point of no return). You can then work on rebuilding the rootfs (possibly using another RPi) once it's running what you want reverse this process - copy it back to /dev/mmcblk0p2 and change /boot/cmdline.txt back to

Code: Select all

dwc_otg.lpm_enable=0 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait
Best of luck with that. If you mess up /boot/cmdline.txt you'll have to de-solder the SDCard.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

stderr
Posts: 2178
Joined: Sat Dec 01, 2012 11:29 pm

Re: Change from XBMC to Standard Desktop from within Linux

Tue Apr 05, 2016 7:11 pm

Mister Parsnips wrote:My question is, whether or not it is possible to get a standard Pi desktop environment on this hard-soldered SD card while removing the XBMC,
Obviously your problem is that the only way you can boot is from an sdcard that if it ever gets corrupted can't be reflashed without melting more solder.

Either you'll have to do that, get a replacement sdcard reader and find some way to hook that up without destroying the traces. Or do what you want to do, find some way to be running linux completely out of memory and then dd back onto the sdcard knowing that any issue after a reboot means you have to break out the iron again.

nicemachines
Posts: 6
Joined: Sun Apr 03, 2016 8:28 pm

Re: Change from XBMC to Standard Desktop from within Linux

Tue Apr 05, 2016 7:39 pm

Interesting Instead of going through all of this that has been said here prior, it might be a lot easier to ask around, maybe someone around still has the old stuff your looking for. Maybe, this little computer has only been on this earth for 4 years, you would think someone would have what your looking for. Really, solder sd cards? WOW! Maybe next time crazy clue it!

Mister Parsnips
Posts: 18
Joined: Wed Jul 25, 2012 5:08 pm

Re: Change from XBMC to Standard Desktop from within Linux

Tue Apr 05, 2016 8:00 pm

Shazaam!!! Thank you very much for that comprehensive reply!! I really appreciate that. I'll follow your instructions meticulously. Perhaps this weekend, since it is supposed to rain anyway.

:D

User avatar
DougieLawson
Posts: 36578
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Change from XBMC to Standard Desktop from within Linux

Thu Apr 07, 2016 7:38 am

Mister Parsnips wrote:Shazaam!!! Thank you very much for that comprehensive reply!! I really appreciate that. I'll follow your instructions meticulously. Perhaps this weekend, since it is supposed to rain anyway.

:D
Edit config.txt once, check twice make sure the root=xxxx part is 100% correct then check again. Let us know how you get on.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

Return to “Beginners”