-
-
Notifications
You must be signed in to change notification settings - Fork 505
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PREP_SYSTEM_FOR_DIETPI.sh | Automate #1285
Comments
Just in theory: If we really get this automated secure for at least some devices, this means we do not necessarily need to create images for those. We could just provide the preparation script to upgrade any Debian system into DietPi. By use of apt-mark, as suggested here: https://github.com/Fourdee/DietPi/pull/1266, we would be sure that possibly disturbing software is removed and provide our own config files/adjustments for our dependencies. Kernel/bootleader apt packages are generally excluded from autoremove on every device I checked. Hehe just a little optimistic view into the feature 😆. |
I like where this is going 👍 |
+ Initial start of: https://github.com/Fourdee/DietPi/issues/1285 NB: failed replace on $OPTION casing WHIP_OPTION
+ Dry run of AGP. continue: https://github.com/Fourdee/DietPi/issues/1285
I've not looked into manual holding packages yet. I'am simply converting the old script into automated. Then we can work on it. |
@Fourdee Just consider: https://github.com/Fourdee/DietPi/pull/1266 If you generally like the idea, I will recreate the PR for the automated script. Other small adjustments based on https://github.com/Fourdee/DietPi/issues/1219#issuecomment-347734540 and following as well. Just tell, after you implemented you ideas, then I will create PR. |
+ DietPi-Software | Plex Media Server: Resolved uninstall to include /var/lib/plexmediaserver in removal (which is not completed via apt purge). + Sparky SBC: Matrix Audio X-SPDIF 2, native DSD is now added to kernel, many thanks @sudeep: sparkysbc/Linux#3 + https://github.com/Fourdee/DietPi/issues/1285
+ Package removal test: https://github.com/Fourdee/DietPi/issues/1285
Scraped, in favor of @MichaIng APT removal method.
|
+ Switch to @MichaIng APT removal method, much more efficent (scrap array based removal): https://github.com/Fourdee/DietPi/issues/1285 + Buster DISTRO
Buster notes:
RPI:
C2:
|
+ Initial pass: https://github.com/Fourdee/DietPi/issues/1285
Note to self: ToDo:
|
Ready for early internal testing to fix bugs and improve. Not stable enough for public users, yet. Tested:
|
|
Legend 👍 In regards to mirror:
1st run
2nd run
This is why I dislike using mirror services. They are unreliable. |
Moved: @Fourdee
By removing the green ones from the list, there should be no additional packages removed. By removing also some of the orange ones, you get the list I used in my PR: https://github.com/Fourdee/DietPi/pull/1266/files#diff-e9e0c6c64b4937739e13ffac58f4a888R74 |
Hehe this is just the wrong URL, use: Going on through the script:
But yeah everything not much more than cosmetic. I can do PR if you want. Otherwise REALLY great work!! 👍 👍 👍 Also found the new fstab creation. Looks really professional! I will test the script tomorrow on my VMs. If we are already touching this:
But both definitely no high priority 😉 |
Epic list https://github.com/Fourdee/DietPi/issues/1285#issuecomment-351888843, many thanks for that 👍 In regards to relying on deps to pull in packages we manually listed (eg: Benefits of listing (example
Firmware: Covers us for all WiFi chipsets etc across all devices. We really should have it in for all images.
Fuse Required for
|
Tweaks based on @MichaIng feedback: https://github.com/Fourdee/DietPi/issues/1285#issuecomment-351888843
@MichaIng
and that's the input I did during script execution
looks like it's detecting a |
@MichaIng |
Hey there! I love dietpi and its low profile. Running it on several ARM Devices and I wanted to convert a freshly installed debian system on a VPS (x64 IONOS) to dietpi. It seems that the conversion completed successfully but after the reboot it dosent boot up. Is there a way to implement an option at the beginning of the script where you can choose the system for IONOS VPS ? Some other guy had the same issue and created a thread in the dietpi forums KVM Console Output:
df -h from a freshly installed debian on the VPS:
Would be nice if someone could help to resolve this issue. Would also test it and provide feedback. Thank you very much! |
Hi, Something to check with Ionos as already recommended on the forum. Probably they don't support installations like DietPi on their platform. |
@rondadon Can you run and paste the output of the following commands from the fresh VPS image?
|
Hi there @MichaIng ... Thank you for trying to help! I appreciate it! Sure I can paste the output of said commands. Here they are! root@localhost:~# cat /etc/fstab
root@localhost:~# df -a
root@localhost:~# blkid
root@localhost:~# lsblk
Again: Thank you for your help. 👍 Have a nice sunday! |
@rondadon
But I'll not find time quickly to implement this ℹ️. Generally the fstab entry works with UUID as well and should be added like this already, so actually the VPS should boot if your run DietPi-PREP and run |
Wow... Thank you very much for your time and help. So I just need to run the DietPi-PREP Script and install lvm2 package manually after the script finished before I reboot the System. Surely I would check And not pressure regarding implementing it into the DietPi-PREP Script. Man, thank you again. I have no words for how thankful I am! :) |
@rondadon Ah please also check if the mapper device is still present: Please also check the following config files before running DietPi-PREP (if it's not yet too late):
Probably the device mapping must be defined there. |
@MichaIng cat /etc/lvm/lvm.conf CLICK ME TO EXPAND
cat /etc/lvm/lvmlocal.conf CLICK ME TO EXPAND
|
@MichaIng root@localhost:~# ls -Al /dev/mapper/
root@localhost:~# cat /etc/fstab
root@localhost:~# df -a
root@localhost:~# blkid
root@localhost:~# lsblk
I then updated the package list with apt-get update, installed lvm2 and dependencies, and changed fstab to following: root@localhost:~# cat /etc/fstab
So basically I commented the line with The I checked again with I rebooted and now I get a different error message in KVM Console. It somehow waits for See Screenshots from KVM Console (Sorry, couldn't copy and paste it): And at the Server Info Page I get this warning: So basically it says that the VMWare Tools are not installed on the server. Maybe it's necessary to install the VMWare Tools to run the mapper devices.?! Will try it again later but additionally install VMWare Tools. Have a nice evening! |
@rondadon
Possibly when removing lvm2, the initramfs is updated to not attempt loading this module. Hence when installing it again, it might be required to update it again to load it. The LVM configs look like defaults, no entries for specific devices. Also to get some more details about the VPS setup:
|
@MichaIng Needed to install the initramfs-tools package to be able tu run Wow... I forgot to run the following prior to running the script. Will revert to the clean debian install and will run this command.
Now converted to dietpi, it boots flawelessly, I can login via ssh and tinker with it. Do you need some info for the dietpi install now? Only the SWAP Partition needs to be mounted now. Man, this made my day... ! |
many thanks for confirmation. I linked the solution back to the forum post to have the loop completed. |
@rondadon
Would be awesome, although not too important as we now know how to make it working 😃.
Yes, you can do the following:
|
So to summerize what I did:
Now the Swapfile is using the space on / (about 1.5GB) so we need to disable the swapfile and enable the SWAP partition of the VMware VPS by doing following (as shown above by Michalng):
Additional Info: df -h before activating SWAP Partition:
df -h AFTER activating SWAP Partition:
Question still to find an answer for:
BTW: I installed debian again and ran the commands mentioned above by @MichaIng . These are the results:
I hope that is all. Thank you again for your effort, help and time to get this resolved! I am really happy now being able to use dietpi on ionos VPS. It uses like 30-40 MB less ram and also about roughly half of the space on / . |
@MichaIng
|
Jep, this has been fixed here: 16a1e9f |
Hello @Fourdee and @MichaIng , It's been a loooong time. I hope you two are doing well in this pandemic age... LOL I have a new challenge... Do you think something like this would work for getting a dietpi image running in a chroot on a Chromebook? I need a thin dev environment and all the targets that I have tried through Crouton are bogging down my older Chromebook. -Rob Kean |
Hi Rob, nice to see you stopping by. Yes did and doing well here during pandemic, luckily coding basically implies limited infection risk 😄. I hope you're doing fine as well. We made large progress to make DietPi + DietPi-PREP running inside a chroot, allowing to automate things. Image creation is currently mostly done by booting images via |
Any chance this dietpi-prep script would work with an older 32 bit laptop? Last I checked debian still supported 32 bit but it's not in the list of choices for dietpi although 32 bit for other architectures IS available. Yes I know 32 bit is ancient but I just have difficulty in tossing a perfectly working laptop into the trash when it's still usable for so many things. |
Hi, I guess this will answer your question. #4024 |
Getting a 404 when trying to get PREP script via raw.githubusercontent.com... Has this been moved to another URL please? |
Yes it has: https://raw.githubusercontent.com/MichaIng/DietPi/master/.build/images/dietpi-installer For reference our updated docs: https://dietpi.com/docs/hardware/#make-your-own-distribution |
Status: Beta
What is this?
What this script does NOT do:
All existing software (APT) and user data will be deleted.
Step 1: Ensure a Debian/Raspbian OS is running on the system
Step 2: Pre-req packages
These should already exist on most systems, however pure minimal images may require the following installations)
apt-get update; apt-get install -y systemd-sysv ca-certificates sudo wget locales --reinstall
Step 3: Run DietPi installer
eg: Outside of desktop environment
Ensure you have elevated privileges (eg: login as
root
, or usesudo su
).Copy and paste all into term.
Follow the onscreen prompts.
The text was updated successfully, but these errors were encountered: