LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 05-04-2019, 05:52 PM   #1
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Live slack w/persistence ... hack


is there a way to get slack live on a SD Card and not a usb stick with persistence. I've been hacking on iso2usb but not getting too far.


it does create all 3 partitions, it just seems to not be able to format them so it fails?
Code:
userx@slack.current.edo:/media/data1/liveslak
$ sudo ./iso2usb.sh -i slackware64-live-current.iso -o /dev/mmcblk0 -f -c 70%
#
# We are going to format this device (erase all data) - '/dev/mmcblk0':
cat: /sys/block/mmcblk0/device/vendor: No such file or directory
cat: /sys/block/mmcblk0/device/model: No such file or directory
# ---------------------------------------------------------------------------
# Vendor : 
# Model  : 
# Size   : 14804 MB
# ---------------------------------------------------------------------------
#
# FDISK OUTPUT:
# GPT fdisk (gdisk) version 1.0.4
# 
# Partition table scan:
# MBR: protective
# BSD: not present
# APM: not present
# GPT: present
# 
# Found valid GPT with protective MBR; using GPT.
# Disk /dev/mmcblk0: 30318592 sectors, 14.5 GiB
# Sector size (logical/physical): 512/512 bytes
# Disk identifier (GUID): 2C695BD8-65D4-4B53-A75E-BD45BEE98C37
# Partition table holds up to 128 entries
# Main partition table begins at sector 2 and ends at sector 33
# First usable sector is 34, last usable sector is 30318558
# Partitions will be aligned on 2048-sector boundaries
# Total free space is 4029 sectors (2.0 MiB)
# 
# Number  Start (sector)    End (sector)  Size       Code  Name
# 1            2048        30316543   14.5 GiB    0700

***                                                       ***
*** If this is the wrong drive, then press CONTROL-C now! ***
***                                                       ***

Or press ENTER to continue: 
1+0 records in
1+0 records out
512 bytes copied, 0.151609 s, 3.4 kB/s
Found valid GPT with corrupt MBR; using GPT and will write new
protective MBR on save.
The operation has completed successfully.
Setting name!
partNum is 0
Setting name!
partNum is 1
Setting name!
partNum is 2
The operation has completed successfully.
The operation has completed successfully.
Disk /dev/mmcblk0: 30318592 sectors, 14.5 GiB
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): 3DC8DAE9-77ED-46F5-A97E-0D14C323FF97
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 30318558
Partitions will be aligned on 2048-sector boundaries
Total free space is 2014 sectors (1007.0 KiB)

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048            4095   1024.0 KiB  EF02  BIOS Boot Partition
   2            4096          208895   100.0 MiB   EF00  EFI System Partition
   3          208896        30318558   14.4 GiB    8300  Slackware Linux
3:2:1 (legacy BIOS bootable)
/dev/mmcblk0
mkfs.fat 4.1 (2017-01-24)
mkdosfs: unable to open /dev/mmcblk01: No such file or directory
*** ./iso2usb.sh FAILED at line 635 ***
--- Cleaning up the staging area...
I just hacked in a hard code to sd card
Code:
# Either provide a block device, or else scan for a block device:
if [ -z "$TARGET" ]; then
  if [ $SCAN -eq 1 ]; then
    echo "-- Waiting  ${SCANWAIT} seconds for a USB stick to be inserted..."
	TARGET=/dev/mmcblk0
  #  TARGET=$(scan_devices)
    if [ -z "$TARGET" ]; then
      echo "*** No new USB device detected during $SCANWAIT seconds scan."
      exit 1
    else
     TARGET=/dev/mmcblk0
   #   TARGET="/dev/${TARGET}"
    fi
  else
    echo "*** You must specify the Live USB devicename (option '-o')!"
    exit 1

Last edited by BW-userx; 05-04-2019 at 05:55 PM.
 
Old 05-05-2019, 02:33 AM   #2
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,058

Rep: Reputation: Disabled
In case of a SD card (eMMC devices), the partitions names are like mmcblk0p1 not mmcbkl01.
 
1 members found this post helpful.
Old 05-05-2019, 05:44 AM   #3
elcore
Senior Member
 
Registered: Sep 2014
Distribution: Slackware
Posts: 1,753

Rep: Reputation: Disabled
Had a mmc install once that worked ok, until power management had cut off power to mmc reader (ricoh on acer) corrupting the partition.
I've given up at that point, maybe you will have better luck.
 
Old 05-05-2019, 08:41 AM   #4
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Original Poster
Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by Didier Spaier View Post
In case of a SD card (eMMC devices), the partitions names are like mmcblk0p1 not mmcbkl01.
I’m going to take a closer look at that and try to figure out them functions as soon as I get a chance. Right now I’m reading this from my phone.
 
Old 05-05-2019, 10:40 AM   #5
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
Quote:
Originally Posted by BW-userx View Post
I’m going to take a closer look at that and try to figure out them functions as soon as I get a chance. Right now I’m reading this from my phone.
Try the modified script which I just uploaded. It should work with your SD card now.
 
2 members found this post helpful.
Old 05-05-2019, 11:50 AM   #6
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,058

Rep: Reputation: Disabled
Quote:
Originally Posted by Alien Bob View Post
Try the modified script which I just uploaded. It should work with your SD card now.
Suggestion: use lsblk instead of fdisk as well to find the partitions names, line 630 would become:
Code:
TARGETP1=$(lsblk -l -o name,type|grep $(echo $TARGET|sed s,/dev/,,)|grep part|cut -d' ' -f1|grep 1$)
Just my 0.02 €

Last edited by Didier Spaier; 05-05-2019 at 11:55 AM.
 
1 members found this post helpful.
Old 05-05-2019, 07:41 PM   #7
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Original Poster
Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by Alien Bob View Post
Try the modified script which I just uploaded. It should work with your SD card now.
results:
see images, 1 is a 16GB, the other is a SDXC 64GB SD Card for the xfce mini build.
Attached Thumbnails
Click image for larger version

Name:	IMG_20190505_192837.jpg
Views:	34
Size:	260.0 KB
ID:	30500   Click image for larger version

Name:	IMG_20190422_125759.jpg
Views:	31
Size:	257.5 KB
ID:	30501  

Last edited by BW-userx; 05-05-2019 at 07:42 PM.
 
Old 05-05-2019, 07:50 PM   #8
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Original Poster
Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by Didier Spaier View Post
Suggestion: use lsblk instead of fdisk as well to find the partitions names, line 630 would become:
Code:
TARGETP1=$(lsblk -l -o name,type|grep $(echo $TARGET|sed s,/dev/,,)|grep part|cut -d' ' -f1|grep 1$)
Just my 0.02 €
HUm? Failed.
Code:
$ sudo ./iso2usb.sh -i /media/data1/slack_iso/slackware64-live-xfce-current.iso  -o /dev/mmcblk0 -c 70%
#
# We are going to format this device (erase all data) - '/dev/mmcblk0':
# ---------------------------------------------------------------------------
# Vendor : 
# Model  : 
# Size   : 60906 MB
# ---------------------------------------------------------------------------
#
# FDISK OUTPUT:
# GPT fdisk (gdisk) version 1.0.4
# 
# Partition table scan:
# MBR: protective
# BSD: not present
# APM: not present
# GPT: present
# 
# Found valid GPT with protective MBR; using GPT.
# Disk /dev/mmcblk0: 124735488 sectors, 59.5 GiB
# Sector size (logical/physical): 512/512 bytes
# Disk identifier (GUID): 87958208-9B46-4D5D-B1ED-BB5FA4695C55
# Partition table holds up to 128 entries
# Main partition table begins at sector 2 and ends at sector 33
# First usable sector is 34, last usable sector is 124735454
# Partitions will be aligned on 2048-sector boundaries
# Total free space is 2014 sectors (1007.0 KiB)
# 
# Number  Start (sector)    End (sector)  Size       Code  Name
# 1            2048            4095   1024.0 KiB  EF02  BIOS Boot Partition
# 2            4096          208895   100.0 MiB   EF00  EFI System Partition
# 3          208896       124735454   59.4 GiB    8300  Slackware Linux

***                                                       ***
*** If this is the wrong drive, then press CONTROL-C now! ***
***                                                       ***

Or press ENTER to continue: 
1+0 records in
1+0 records out
512 bytes copied, 0.00616721 s, 83.0 kB/s
Found valid GPT with corrupt MBR; using GPT and will write new
protective MBR on save.
The operation has completed successfully.
Setting name!
partNum is 0
Setting name!
partNum is 1
Setting name!
partNum is 2
The operation has completed successfully.
The operation has completed successfully.
Disk /dev/mmcblk0: 124735488 sectors, 59.5 GiB
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): 494AE683-67EF-406C-A943-6ED8C6ADE6EC
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 124735454
Partitions will be aligned on 2048-sector boundaries
Total free space is 2014 sectors (1007.0 KiB)

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048            4095   1024.0 KiB  EF02  BIOS Boot Partition
   2            4096          208895   100.0 MiB   EF00  EFI System Partition
   3          208896       124735454   59.4 GiB    8300  Slackware Linux
3:2:1 (legacy BIOS bootable)
TARGET1->: 
mkfs.fat 4.1 (2017-01-24)
mkdosfs: unable to open mmcblk0p1: No such file or directory
*** ./iso2usb.sh FAILED at line 638 ***
--- Cleaning up the staging area...
changed that line to yours, and echo'ed it too just to see what it is suppose to have. it is blank???

Last edited by BW-userx; 05-05-2019 at 07:51 PM.
 
Old 05-05-2019, 08:17 PM   #9
linus72
LQ Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: Slack14.2/Many
Posts: 5,573

Rep: Reputation: 470Reputation: 470Reputation: 470Reputation: 470Reputation: 470
hack it manually bro and see if it works...thats what I do
 
Old 05-06-2019, 01:52 AM   #10
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,058

Rep: Reputation: Disabled
Quote:
Originally Posted by BW-userx View Post
HUm? Failed.
The change I suggested is just another way to feed the variables, in other words cosmetic.

Anyway, before we go further please provide the full output of this command, typed with the SD card plugged in:
Code:
lsblk -l -o vendor,model,name,size,type,fstype,pkname,mountpoint,rm
 
Old 05-06-2019, 04:33 AM   #11
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
Quote:
Originally Posted by BW-userx View Post
results:
see images, 1 is a 16GB, the other is a SDXC 64GB SD Card for the xfce mini build.
I understand from this that the SD card was properly written using my modified script.
But when you boot it next, the Live init process fails to find the SD card. I guess I will have to enhance the liveinit.tpl file as well to add support for SD cards. I'll have a look.
 
1 members found this post helpful.
Old 05-06-2019, 05:51 AM   #12
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
Quote:
Originally Posted by Alien Bob View Post
I understand from this that the SD card was properly written using my modified script.
But when you boot it next, the Live init process fails to find the SD card. I guess I will have to enhance the liveinit.tpl file as well to add support for SD cards. I'll have a look.
Hmmm looking at the first picture, it says "Live media found at /dev/sda1" which will in no way be your SD card. Did you perhaps have a CDROM inserted in the drive with a Slackware Live ISO copied onto it? Because when liveslak encounters multiple media containing Slackware Live, it will just pick the first one in the list and that will not always be the correct one.

The second picture has kernel symbol errors. Did you add a custom kernel and/or modules to that ISO image?
 
Old 05-06-2019, 07:42 AM   #13
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Original Poster
Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by Alien Bob View Post
Hmmm looking at the first picture, it says "Live media found at /dev/sda1" which will in no way be your SD card. Did you perhaps have a CDROM inserted in the drive with a Slackware Live ISO copied onto it? Because when liveslak encounters multiple media containing Slackware Live, it will just pick the first one in the list and that will not always be the correct one.

The second picture has kernel symbol errors. Did you add a custom kernel and/or modules to that ISO image?
that is what I was wondering why is it looking at sda1.
why is it is showing anything about trying to get to sda1?

With you mentioning a CDROM, that has to be (maybe) for the HP EliteBook 8460p that has SATA hdd, and a combo DVD / secondary hdd setup, where I have a secondary hdd in lue of the DVD that use to be in it. (perhaps).

I have the directories that have all of the staging and liveslck on that hdd. Because my root partition on this Laptop is at no room, it kept going to zero space left, to the point it is now screwed up when I did an system update and I am now getting file too short errors when it tries to use any lib.so and I can no longer startx having given it room again. but that is another issue I got a deal with on that laptop.

HP EliteBook 8460p

32GB ssd and 250GB ssd

I got two distros installed on a 32GB ssd, VOID Linux and Slack current, and I now it is running out of space on both during updates. so I am sitting here wondering what or which one to remove. Slack current is taking up more than 15GB. which this is totally side tracking this SD Card issue.
------------------

the other Laptop is a HP EliteBook 840 g2 No CD/DVD and as far as I see only gives me SD Card boot option when I use the UEFI and legacy combo or pure UEFI boot option in BIOS. SATA hdd, and M.2 PCIe Solid State Drive. that M.2 is seen as /dev/sdb and that is where I have to direct it to install grub and boot from sdb, and not sda. That (sda) is being used as a data storage drive.

Just trying to boot that in Legacy mode the BIOS removes the option to use the SD Card off the list in BIOS.

I probably gave you more info then needed/wanted, so while you're picking your brain on that, I'll be trying to figure out what to do with this no space left hp 8460p laptop, and dealing with that, something I did not have on my list of things to do, before I can get back to the SD Card thing.

Last edited by BW-userx; 05-06-2019 at 07:50 AM.
 
Old 05-06-2019, 08:13 AM   #14
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Original Poster
Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by Didier Spaier View Post
The change I suggested is just another way to feed the variables, in other words cosmetic.

Anyway, before we go further please provide the full output of this command, typed with the SD card plugged in:
Code:
lsblk -l -o vendor,model,name,size,type,fstype,pkname,mountpoint,rm
I just did yours because the other messed up so I did it to see what it would do, then posted back my results. as I am now dealing with slack no room screwed up update on the hp 8460p right now, I'll get back to your request when I am done with that. sorry I cannot post that put someone on hold music here. or I'd play you something nice to listen to.

Or as I am on the usb slack stick right now on the hp 8460p to redo my partitions so I can fix this dual distro no room left situation. so...
Code:
bob@deathstar.net:~
$ lsblk -l -o vendor,model,name,size,type,fstype,pkname,mountpoint,rm
VENDOR  MODEL              NAME         SIZE TYPE  FSTYPE  PKNAME  MOUNTPOINT RM
                           loop0         16M loop  squashf                     0
                           loop1      255.8M loop  squashf                     0
                           loop2      158.9M loop  squashf                     0
                           loop3      432.4M loop  squashf                     0
                           loop4       42.5M loop  squashf                     0
                           loop5        7.6M loop  squashf                     0
                           loop6      120.3M loop  squashf                     0
                           loop7      707.9M loop  squashf                     0
                           loop8      402.5M loop  squashf                     0
                           loop9      330.2M loop  squashf                     0
                           loop10     116.6M loop  squashf                     0
                           loop11      98.6M loop  squashf                     0
                           loop12       5.8M loop  squashf                     0
                           loop13     143.3M loop  squashf                     0
                           loop14     235.3M loop  squashf                     0
                           loop15      13.3M loop  squashf                     0
                           loop16       2.1M loop  squashf                     0
                           loop17       4.9M loop  squashf                     0
                           loop18       6.4M loop  squashf                     0
                           loop19     364.5M loop  squashf                     0
                           loop20      18.3G loop  crypto_                     0
ATA     KingFast           sda         29.8G disk                              0
                           sda1           8G part  ext4    sda     /media/dat  0
                           sda2        15.1G part  ext4    sda     /media/ntf  0
                           sda3         3.3G part  ext4    sda                 0
                           sda4         2.4G part  ext4    sda                 0
ATA     Samsung_SSD_850_EV sdb        232.9G disk                              0
                           sdb1       232.9G part  ext4    sdb                 0
Samsung Flash_Drive_FIT    sdc         29.9G disk                              1
                           sdc1           1M part  vfat    sdc                 1
                           sdc2         100M part  vfat    sdc                 1
                           sdc3        29.8G part  ext4    sdc                 1
                           mmcblk0     14.5G disk                              0
                           mmcblk0p1    100M part  vfat    mmcblk0             0
                           mmcblk0p2   14.4G part  ntfs    mmcblk0             0
                           slhome_img  18.3G crypt         loop20  /home       0
bob@deathstar.net:~

Last edited by BW-userx; 05-06-2019 at 08:16 AM.
 
Old 05-06-2019, 10:43 AM   #15
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Original Poster
Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Ha Ha Ha haaaaaha

this is off a fresh install of current iso and a system update
now what?
Code:
userx@slack.curry.org:/media/data1/liveslak
$ sudo ./make_slackware_live.sh
-- Loading configuration file.
#SL_REPO: 
-- Creating liveslak 1.3.1.1 'XFCE' image (based on Slackware-current x86_64).
Parallel unsquashfs: Using 8 processors
7 inodes (12 blocks) to write

[=================================================================|] 12/12 100%

created 3 files
created 2 directories
created 4 symlinks
created 0 devices
created 0 fifos
-- Configuring the base system.
chroot: failed to run command ‘/usr/sbin/chpasswd’: No such file or directory
*** ./make_slackware_live.sh FAILED at line 1420 ***
--- Cleaning up the staging area...
userx@slack.curry.org:/media/data1/liveslak
$ ls /usr/sbin/chpasswd
/usr/sbin/chpasswd
userx@slack.curry.org:/media/data1/liveslak
$ file /usr/sbin/chpasswd
/usr/sbin/chpasswd: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, with debug_info, not stripped
userx@slack.curry.org:/media/data1/liveslak
$
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Raspberry Pi OS Update to hack WiFi Hack LXer Syndicated Linux News 0 08-20-2017 02:12 PM
Hack, hack, hacking away!! cousinlucky General 6 07-09-2015 01:01 PM
persistence in debian live usb ciden Linux - Desktop 0 09-09-2007 12:18 PM
Live CD Persistence ArthurDent Ubuntu 4 10-29-2006 03:30 PM
Hack Hack anoop_chandran Linux - General 9 12-07-2001 10:38 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 07:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration