Jump to content


Photo

dreambox secondstage dependence & dFlash plugin (by gutemine)

dflash

  • Please log in to reply
61 replies to this topic

Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #21 zeros

  • PLi® Contributor
  • 1,635 posts

+61
Good

Posted 11 January 2015 - 19:50

Let it be, better to talk about things. I'm pretty well logged dFlash activities. Is quite true that the so-called 'time bomb inside dFlash. By luck, I was able to maintain the ability to work and I have a completely working version of this day there. Unfortunately, every person applying the right ipk to his box for a pretty simple way to install it is not working, or else the Backup size is still zero. But we can easily make a beautiful dFlash resetter, so that it will work. dFlash 13.x also make full backup, that can flash via webinterface. For an earlier version dreamup or dFlash themselves. Restoring a backup of all of the tried and tested by me, they work as promised.

DM920UHD DVB-S2X TRIPLE tuner + Triple M.S tuner DVB-S2X, DVB-T2/T, QboxHD, QboxHD Mini, Icecrypt T2300HD,
Qviart Lunix3 4K, Raspberry Pi 4 Model B 4GB & 8GB

Vertex 4K60 4:4:4 600MHz


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #22 wortellica

  • Senior Member
  • 1,370 posts

+33
Good

Posted 12 January 2015 - 05:33

No, you can use that script https://github.com/s...x-fullbackup.sh

We are using it at SatDreamGR image without problems.

You need build-image on feeds and one patch for mtd-utils.

Patches made available to OpenPLi, but not commited/accepted yet.

Why is it not accepted yet by pli yet ?



Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #23 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 12 January 2015 - 16:23

No, you can use that script https://github.com/s...x-fullbackup.sh

We are using it at SatDreamGR image without problems.

You need build-image on feeds and one patch for mtd-utils.

Patches made available to OpenPLi, but not commited/accepted yet.

Why is it not accepted yet by pli yet ?

 
Maybe because it is not nessesary for other boxes... Here is the (gutemine's) mtd patch: https://github.com/o...from-dump.patch missing from OpenPLi.
 
The buildimage should be already on the feeds.
 
I guess it easy to modify the script to do the trim. Something like the following will do the trim job:
 
 
cutoff = 0
while IFS= read -rn1 ch
  if [ ch -eq 0xFFFFFFFF ]; then
    break
  fi
  cutoff=$(($cutoff+1))
done < secondstage.bin
 
dd if=secondstage.bin of=secondstage.trimmed.bin bs=1 count=$cutoff
 
So the idea is to read the secondstage.bin (byte,byte) untill 0xFFFFFFFF is found, increasing cutoff counter. Then use dd to trim secondstage up to cutoff bytes.
 
With the above it is not required to have mtd-utils patch and bash script can be adapted by popular backup progrems (eg Backup Suite).

Edited by athoik, 12 January 2015 - 16:24.

Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #24 zeros

  • PLi® Contributor
  • 1,635 posts

+61
Good

Posted 12 January 2015 - 20:16

These temporary files occure in the media where the backup will be:
swapfile
r.ubi
b.img
s.bin

 

ubinize.cfg - /var/volatile/tmp

 

Attached Files


DM920UHD DVB-S2X TRIPLE tuner + Triple M.S tuner DVB-S2X, DVB-T2/T, QboxHD, QboxHD Mini, Icecrypt T2300HD,
Qviart Lunix3 4K, Raspberry Pi 4 Model B 4GB & 8GB

Vertex 4K60 4:4:4 600MHz


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #25 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 12 January 2015 - 21:45

Is it possible somebody to run the following command and upload /tmp/secondstage.bin here?

/usr/sbin/nanddump --noecc --omitoob --bb=skipbad  --file=/tmp/secondstage.bin /dev/mtd1
I don't have a powered dreambox atm that's why I am asking above file. Thanks
Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #26 catastrofus

  • Senior Member
  • 3,480 posts

+43
Good

Posted 13 January 2015 - 10:00

root@nestorix:~# /usr/sbin/nanddump --noecc --omitoob --bb=skipbad  --file=/tmp/secondstage.bin /dev/mtd1
Block size 262144, page size 4096, OOB size 128
Dumping data starting at 0x00000000 and ending at 0x00100000...
root@nestorix:~# ls -l /tmp/secondstage.bin
-rw-r--r--    1 root     root       1048576 Jan 13 09:56 /tmp/secondstage.bin
root@nestorix:~#

 

Attached Files


Edited by catastrofus, 13 January 2015 - 10:03.

2 x vu+ultimo4k ((nb & 9.0r) dvb-c fbc + 1 dvb-s2) + een vu+duo4k ((nb) fallbackclient) met een Synology ds214+ (2 x 6 TB) op DSM 7.1.1 in ziggo oost (voormalig @Home) + A1/A2/A3/HB (TechniSat)
 


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #27 asdas11

  • Senior Member
  • 55 posts

0
Neutral

Posted 13 January 2015 - 10:29

Hi,

i read this discussion  and can't understand is or no some dflash plugin  to do backup in DM800se? :o



Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #28 zeros

  • PLi® Contributor
  • 1,635 posts

+61
Good

Posted 13 January 2015 - 11:05

It is not so easy getting to work it. It makes an initial backup, the size of which is zero. There is workaorund, but we are still working on it.


DM920UHD DVB-S2X TRIPLE tuner + Triple M.S tuner DVB-S2X, DVB-T2/T, QboxHD, QboxHD Mini, Icecrypt T2300HD,
Qviart Lunix3 4K, Raspberry Pi 4 Model B 4GB & 8GB

Vertex 4K60 4:4:4 600MHz


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #29 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 13 January 2015 - 13:01

Here is the latest change in satdreamgr dreambox-fullbackup.sh

#
# Export secondstage
#
log "Exporting secondstage"
/usr/sbin/nanddump --noecc --omitoob --bb=skipbad --file="$SECSTAGE" /dev/mtd1
if [ $? -ne 0 ] && [ ! -f "$SECSTAGE" ] ; then
   log "Error: nanddump failed to dump secondstage!"
   exit 8
fi

#
# Trim 0xFFFFFF from secondstage
#
/usr/bin/python -c "
data=open('$SECSTAGE', 'rb').read()
cutoff=data.find('\xff\xff\xff\xff')
if cutoff:
    open('$SECSTAGE', 'wb').write(data[0:cutoff])
"
It doesn't use the gutemine "--truncate" option in nanddump, but instead it truncates the file with the help of python.

So using the attached dreambox-fullbackup.sh you will be able to take Dreambox full backup on OpenPLi without any propertiary code...

Everything required should be in the OpenPLi feeds.

Please report if the script works in order to commit the change.

PS. You need to make script executable (chmod +x dreambox-fullbackup.sh)

Attached Files


Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #30 zeros

  • PLi® Contributor
  • 1,635 posts

+61
Good

Posted 14 January 2015 - 07:44

 

Everything required should be in the OpenPLi feeds.

 

Hi athoik !

Could you give a brief guide/references on what is required to install or have, to test the satdreamgr? I will then try it over the weekend and will give you feedback how the things are going with DM 7020HD


Edited by zeros, 14 January 2015 - 07:44.

DM920UHD DVB-S2X TRIPLE tuner + Triple M.S tuner DVB-S2X, DVB-T2/T, QboxHD, QboxHD Mini, Icecrypt T2300HD,
Qviart Lunix3 4K, Raspberry Pi 4 Model B 4GB & 8GB

Vertex 4K60 4:4:4 600MHz


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #31 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 14 January 2015 - 07:56

The above script... it will create backup in /media/hdd or /media/usb. Feeds must include all available packages.
Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #32 zeros

  • PLi® Contributor
  • 1,635 posts

+61
Good

Posted 14 January 2015 - 08:38

Hence there is no need of any special package in order to install, just run this script from the command line? OK, I'll try in Saturday. It would be nice if someone else try it and report the results.


DM920UHD DVB-S2X TRIPLE tuner + Triple M.S tuner DVB-S2X, DVB-T2/T, QboxHD, QboxHD Mini, Icecrypt T2300HD,
Qviart Lunix3 4K, Raspberry Pi 4 Model B 4GB & 8GB

Vertex 4K60 4:4:4 600MHz


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #33 zeros

  • PLi® Contributor
  • 1,635 posts

+61
Good

Posted 14 January 2015 - 10:51

I add a difference in dFlash log, where the backup ends at zero:

/tmp/dFlash/bin/mkfs.jffs2: error while loading shared libraries: liblzo2.so.2: cannot open shared object file: No such file or directory
+ /tmp/dFlash/bin/sumtool --input=/media/GOODRAM/backup/b.img --output=/media/GOODRAM/backup/bs.img -e 262144 -n -l
sumtool: error!: open input file
         error 2 (No such file or directory)

I just compared the running dFlash log file dbackup.log with non-working version.

Attached Files


DM920UHD DVB-S2X TRIPLE tuner + Triple M.S tuner DVB-S2X, DVB-T2/T, QboxHD, QboxHD Mini, Icecrypt T2300HD,
Qviart Lunix3 4K, Raspberry Pi 4 Model B 4GB & 8GB

Vertex 4K60 4:4:4 600MHz


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #34 zeros

  • PLi® Contributor
  • 1,635 posts

+61
Good

Posted 14 January 2015 - 19:33

After first test with the satdreamgr dreambox-fullbackup.sh Shell Script, my results:

 

root@dm7020hd:/var/volatile/tmp# chmod +x dreambox-fullbackup.sh
root@dm7020hd:/var/volatile/tmp# bash dreambox-fullbackup.sh
20:21 Checking Dependencies...
Downloading http://downloads.pli...0hd/Packages.gz.
Updated list of available packages in /var/lib/opkg/openpli-3rd-party-dm7020hd.
Downloading http://downloads.pli...rty/Packages.gz.
Updated list of available packages in /var/lib/opkg/openpli-3rd-party.
Downloading http://downloads.pli...all/Packages.gz.
Updated list of available packages in /var/lib/opkg/openpli-all.
Downloading http://downloads.pli...0hd/Packages.gz.
Updated list of available packages in /var/lib/opkg/openpli-dm7020hd.
Downloading http://downloads.pli...2el/Packages.gz.
Updated list of available packages in /var/lib/opkg/openpli-mips32el.
Installing mtd-utils-jffs2 (1.5.1+git0+9f107132a6-r0.8) on root.
Downloading http://downloads.pli....8_mips32el.ipk.
Configuring mtd-utils-jffs2.
Installing mtd-utils-ubifs (1.5.1+git0+9f107132a6-r0.8) on root.
Downloading http://downloads.pli....8_mips32el.ipk.
Configuring mtd-utils-ubifs.
Installing dreambox-buildimage (1.4+git0+7b3b94efd0-r1.1) on root.
Downloading http://downloads.pli....1_mips32el.ipk.
Configuring dreambox-buildimage.
20:22 Found Dreambox dm7020hd ...
20:22 Error: Backup Location not found!
 


DM920UHD DVB-S2X TRIPLE tuner + Triple M.S tuner DVB-S2X, DVB-T2/T, QboxHD, QboxHD Mini, Icecrypt T2300HD,
Qviart Lunix3 4K, Raspberry Pi 4 Model B 4GB & 8GB

Vertex 4K60 4:4:4 600MHz


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #35 zeros

  • PLi® Contributor
  • 1,635 posts

+61
Good

Posted 14 January 2015 - 19:45

I looked into the script-

my backup location should be USB stick:

/media/GOODRAM

better, I made the folder backup, so:

/media/GOODRAM/backup

 

In script it says /media/hdd or I don't understand, how exactly the USB should be described. There is a way but I just check it.


DM920UHD DVB-S2X TRIPLE tuner + Triple M.S tuner DVB-S2X, DVB-T2/T, QboxHD, QboxHD Mini, Icecrypt T2300HD,
Qviart Lunix3 4K, Raspberry Pi 4 Model B 4GB & 8GB

Vertex 4K60 4:4:4 600MHz


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #36 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 14 January 2015 - 19:51

There is not /media/usb and not /media/hdd

if [ -z $1 ] ; then
 if [ -d /media/usb ] && df /media/usb 1>/dev/null 2>/dev/null ; then
  BACKUP_LOCATION="/media/usb"
 elif [ -d /media/hdd ] && df /media/hdd 1>/dev/null 2>/dev/null ; then
  BACKUP_LOCATION="/media/hdd"
 else
  log "Error: Backup Location not found!"
  exit 2
 fi
elif [ -d $1 ] && [ $1 != "/" ] && df $1 1>/dev/null 2>/dev/null ; then
 BACKUP_LOCATION=$1
else
 log "Error: Invalid Backup Location $1"
 exit 2
fi
log "Backup on $BACKUP_LOCATION"
If you have another location (eg /media/hdd1) you need to run it with argument /media/hdd1
Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #37 Pedro_Newbie

  • Senior Member
  • 4,631 posts

+225
Excellent

Posted 14 January 2015 - 19:53

Change the lines 87 & 88 in your case from

   if [ -d /media/usb ] && df /media/usb 1>/dev/null 2>/dev/null ; then
      BACKUP_LOCATION="/media/usb"

into

   if [ -d /media/GOODRAM ] && df /media/GOODRAM 1>/dev/null 2>/dev/null ; then
      BACKUP_LOCATION="/media/GOODRAM/backup"

and try again

 



Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #38 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 14 January 2015 - 19:54

Change the lines 87 & 88 in your case from


No need to change something, just pass the location as argument.
Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916

Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #39 Pedro_Newbie

  • Senior Member
  • 4,631 posts

+225
Excellent

Posted 14 January 2015 - 19:58

You mean

bash dreambox-fullbackup.sh /media/GOODRAM/backup
?

Edited by Pedro_Newbie, 14 January 2015 - 19:58.


Re: dreambox secondstage dependence & dFlash plugin (by gutemine) #40 athoik

  • PLi® Core member
  • 8,458 posts

+327
Excellent

Posted 14 January 2015 - 20:06

You mean

bash dreambox-fullbackup.sh /media/GOODRAM/backup
?


dreambox-fullbackup.sh /media/GOODRAM

elif [ -d $1 ] && [ $1 != "/" ] && df $1 1>/dev/null 2>/dev/null ; then
 BACKUP_LOCATION=$1
The backup folder is created automatically.

mkdir -p "$BACKUP_LOCATION/backup"

Wavefield T90: 0.8W - 1.9E - 4.8E - 13E - 16E - 19.2E - 23.5E - 26E - 33E - 39E - 42E - 45E on EMP Centauri DiseqC 16/1
Unamed: 13E Quattro - 9E Quattro on IKUSI MS-0916



Also tagged with one or more of these keywords: dflash

2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users