WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Help for Newbie: offline installation of tcz packages in texmode  (Read 843 times)

Offline Tambry

  • Newbie
  • *
  • Posts: 4
Help for Newbie: offline installation of tcz packages in texmode
« on: September 09, 2024, 02:59:58 PM »
I just set up my Fileserver and its backup with Lubuntu 24.04 LTS and configured rsnapshot and samba by the terminal only - but I am still a Linux-Newbie...so sorry for my stupid questions (not sure if I have my post even in the right category).

I want to learn more and as goal, I want to install a Linux on my NAS (QNAP TS-451), and have ssh, samba and mdadm installed to use it ...well, as a NAS (but without any clutter and me in full control). Local storage holding the OS is a USB drive with 400 MB (MB, not GB). This lead me to Tiny Core and I can install it with the Core Plus CD, use the GUI, enable my USB-WiFi and download and install all needed packages. This showed me that TC can run on the NAS.

To learn, I would like to repeat the installation but with no GUI and no Internet  (ie not using the Appbrowser). How/Where can I download the required tcz files from the repository? Can I then just put them on a USB disk, mount it and install with tce-load from it?
« Last Edit: September 09, 2024, 03:15:06 PM by Tambry »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #1 on: September 09, 2024, 03:50:54 PM »
Hi Tambry
Welcome to the forum.

... How/Where can I download the required tcz files from the repository? ...
The latest 32 bit versions are here:
http://tinycorelinux.net/15.x/x86/tcz/

The latest 64 bit versions are here:
http://tinycorelinux.net/15.x/x86_64/tcz/

You might want to consider taking an hour to read the fine book found here:
http://tinycorelinux.net/book.html

Offline CentralWare

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 770
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #2 on: September 10, 2024, 03:12:06 AM »
I want to learn more and as goal, I want to install a Linux on my NAS (QNAP TS-451)

@Tambry: Welcome to TinyCore!

QNAP already has a custom linux image running on it, and yes, it's full of bloat and restrictions galore where third party repositories are required just to get it to operate a little more Linux'y.
WARNING: Modifying the firmware is a one-shot deal!  Be sure you have ALL of the necessary VIDEO, USB, STORAGE and NETWORK drivers before you begin; once you've overwritten the internal 512MB'ish flash there's no turning back!

I have the x31 series units here (ARM based) and not the x51 (Celeron based) so I cannot walk you through the process directly, but can give you a few pointers to make the transition easier.  Bare in mind, the QNAP systems are usually not your standard run of the mill motherboard with BIOS that's accessible and programmable by the end user which will boot by CD/DVD or USB (or not that I was aware of...)  That would make your task too easy! :)  Based on your details, here is your system from inside.

IF the above matches your system (Dual Core Celeron) we'll need to dig a little deeper and determine the NETWORK hardware as Power-Up didn't mention it and I cannot zoom in close enough to tell what chipset it runs off of.  I'm assuming it uses the same chips as it's big brother, the 451+ (Intel WGI210AT 1GBe chips)

If your standard Linux kernel and/or third party drivers are readily available, start collecting them before making any attempt at installing Linux of ANY flavor permanently.  You'll also want to create a DD image of the flash as it stands right now "just in case."

Before considering replacing your existing Linux kernel, I'm going to recommend USING the existing setup to get rid of the bloat; this way you can always "Factory Reset" if you get yourself into trouble.  The first thing you need to do, however, is to offload any and all files on the device that you want to keep -- they may not survive the trip!

Once your system is good to experiment with, search G00gle for QNAP third party repositories such as MyQNAP if they still exist.  You'll find instructions on how to use the APPS console to install the repository.  Once installed, search that repo for a package called ENTware.  This is vital at this stage as it'll give you access to software extensions that QNAP otherwise doesn't make available to you - which is "most everything else" found in a Linux environment.

Once you've located and installed ENTware, go into your Control Panel > Telnet/SSH and ENABLE SSH if you haven't already.  SSH is going to become your new best friend since you'll be getting rid of QTS in the end, which is their web-based control system.  If you prefer to connect a keyboard and HDMI monitor, you can also (likely) do all of this from the QNAP itself instead of SSH, but I don't know the limitations of the x51 series of what you see on the screen; whether it's the shell or their version of a desktop.  The shell is preferred.

Once ENTware is installed, go into the shell and install pciutils and usbutils which is going to help us determine your exact hardware setup
Code: [Select]
ipkg update
ipkg install pciutils
ipkg install usbutils
NOTE: I have ENTware installed on two different ARM platforms (ARM6 and ARM7) and the app is "ipkg" on one and "opkg" on the other...  if the above complains about not being able to find ipkg... switch to opkg instead.

Afterward, create a number of text files to attach here on the forum
Code: [Select]
dmesg > /mnt/Public/dmesg.txt
uname -a > /mnt/Public/uname.txt
pciutils > /mnt/Public/pciutils.txt
usbutils > /mnt/Public/usbutils.txt
NOTE: This assumes you still have the default Public share set up.  Change "Public" to one of your share folder names if you do not.

Get this far and return here with your experiences and attach your files.  You may have to attach dmesg.txt separately depending on its size.

@Rich: I have to go "under the knife" (so to speak) in a few hours and may not be back online for a bit.  Head over to the links I posted above if you would, please, and check to see if the chipsets Power-Up did list are in fact kernel supported.  I believe the major differences between the 451 and 451+ were the enclosures themselves, the CPU (Dual vs. Quad) and I THINK the PSU, but I cannot be certain as that was a decade'ish ago and like when you're out fishing...  something that small usually gets thrown back, and with such a high price tag (at the time)...  I was happy to do just that; we purchased a half dozen or so Atom boards and built our own devices for roughly the same price as one of theirs and ended up using Webmin as a really easy control panel that fit the bill perfectly for what the devices were intended - almost completely ready to run out of the box :)

Good luck!

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #3 on: September 10, 2024, 10:45:39 AM »
Hi CentralWare
... determine the NETWORK hardware as Power-Up didn't mention it and I cannot zoom in close enough to tell what chipset it runs off of. ...
Near the bottom of the page they show an image of the board labeled:
"On the mainboard's solder side are also a pair of Intel WGI210AT Ethernet controllers."
That's the igb driver.

I see no driver for this:
"The hardware monitor IC, a Fintek F71869AD."

I see no driver for this:
"An Asmedia ASM1442 controls the HDMI port the HD Station exploits."

This one should be OK:
"The CPU is passively cooled by a small heatsink. It is an Intel Celeron J1800 (Bay Trail) with two cores running at 2.41 GHz."

I had to deal with a Bay Trail in a netbook (Asus T100CHI). Needed to build a kernel
with extra options, most of which were added to later kernel configs, including these:
Code: [Select]
CONFIG_I2C_DESIGNWARE_BAYTRAIL=y
CONFIG_PINCTRL_BAYTRAIL=y

I don't know if it matters, this is not set:
Code: [Select]
# CONFIG_INTEL_SOC_PMIC is not set

Offline CentralWare

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 770
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #4 on: September 10, 2024, 01:19:02 PM »
@Rich:
Near the bottom of the page they show an image of the board labeled:
...update.pdf]WGI210AT[/url] Ethernet controllers.
That's the igb driver.

I see no driver for this: "The hardware monitor IC, a Fintek F71869AD."
I see no driver for this: "An Asmedia ASM1442 controls the HDMI port the HD Station exploits."
This one should be OK: "The CPU is passively cooled by a small heatsink. It is an Intel Celeron J1800 (Bay Trail) with two cores running at 2.41 GHz."

I had to deal with a Bay Trail in a netbook (Asus T100CHI). Needed to build a kernel...
Code: [Select]
CONFIG_I2C_DESIGNWARE_BAYTRAIL=y
CONFIG_PINCTRL_BAYTRAIL=y

I don't know if it matters, this is not set:
Code: [Select]
# CONFIG_INTEL_SOC_PMIC is not set

NOTES:
Fintek: https://github.com/torvalds/linux/blob/master/drivers/gpio/gpio-f7188x.c
ASMedia:  (Possible Reference - need hardware ID) https://linux-hardware.org/?id=pci:1b21-1242-1043-8675
KERNEL:CONFIG_INTEL_SOC_PMIC: I don't see a reference to Crystal Cove, but noted "just in case."

Quote
That's the igb driver.
Please elaborate?  (In the Garbage Bin? :) )
This guy: ? https://www.intel.com/content/www/us/en/support/articles/000005480/ethernet-products.html
Didn't we already have an e1000 driver built at one point?  Or is that in the kernel these days?

Then again, not exactly seeing "straight" @ the moment, pain meds haven't worn off yet :P so all references to grey matter memory...  currently on hiatus...

Ya' know... I'm not investing right now as I don't really have justification, but I'm rather intrigued.
I was pondering doing a complete open-heart bypass on different Buffalo and QNAP (ARM based) NAS devices not all that long ago, mainly because their "recovery" options are almost nil if the unit goes kaput... but I just added Intel/AMD based NAS units to the "Maybe To Do" list along with the ARM units still humming away in my personal repository storage (which were already hacked to double as dns/dhcp/tftp/ntpd and a few other things Buffalo intentionally left out of their desktop models and QNAP...  well, they started off great, BUT THEN...)

Thank you for your efforts, my good Sir!

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #5 on: September 10, 2024, 01:33:45 PM »
Hi CentralWare
... Please elaborate?  (In the Garbage Bin? :) ) ...
That would be these:
Code: [Select]
CONFIG_IGB=m
CONFIG_IGB_HWMON=y
CONFIG_IGBVF=m

Quote
... Didn't we already have an e1000 driver built at one point?  Or is that in the kernel these days? ...
Yes, that would be these:
Code: [Select]
CONFIG_E1000=m
CONFIG_E1000E=m
CONFIG_E1000E_HWTS=y

Offline CentralWare

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 770
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #6 on: September 10, 2024, 01:56:21 PM »
Thank you, my friend!  I saw a module for E100 (10-baseT and 100-baseT I'd assume) but no mention from TCE via keywords or provides as to E1000 or IGB (14x64) so I thought maybe it became part of the Core or something.  I'll dig a little deeper when the time comes or go see where the sorter lives these days and reverse-eyeball it. :)

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #7 on: September 10, 2024, 02:08:35 PM »
Hi CentralWare
They are part of the base under:
Code: [Select]
/lib/modules/$KERNEL/kernel/drivers/net/ethernet/intel/

Offline Tambry

  • Newbie
  • *
  • Posts: 4
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #8 on: September 10, 2024, 03:13:23 PM »
Dear all,
thanks alot for all your replies...I missed the extended instructions book. I started reading through it...

About the hardware of the TS-451 (yes, CentralWare, the link you provided is dead-on)
the original OS is stored on a standard 500MB USB2 DOM, connected to the mainboard with the usual USB2 mainboard-pinheaders. So my first action was to take out the board, attach a normal female USB2 connector to it so that I can use any USB stick as new location to install a new OS. This way I can really play around while the original OS is safe. Additionally I ran clonezilla, saw the internal 'harddrive' and made an image of it. So I can really play around and test to my hearts content - while still keeping the original USB DOM safe. Currently I have a 64GB USB stick connected for trials.

I can start the live-DVD from Lubuntu 24.04 without problems and it tells me the CPU is indeed the Intel Celeron J1800 and I can get a resolution of 1920x1080 without problems (using the HDMI output on a huge TV).
"ip addr show" shows me two physical NICs (enp3s0 and enp4s0) and "ethtool -i enp3s0" gives:
driver: igb (so, just as Rich pointed out, a driver exists) version: 6.8.0-31-generic
But when trying to install LUbuntu (on the USB stick), it cannot install the bootloader ("the installation command <pre>grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=ubuntu --force</pre> returned error code 1")...weird
On the other side Tiny Core Linux boots from the same USB stick without problem...well, my plan was to install Tiny Core anyways...

The next days I will try to install the "Core" on the USB stick without internet access and try to manually add the few packages that I need..
« Last Edit: September 10, 2024, 03:31:43 PM by Tambry »

Offline gadget42

  • Hero Member
  • *****
  • Posts: 815
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #9 on: September 19, 2024, 02:50:55 AM »
this recent commentary on botnets specifically mentions qnap ts-* series devices

https://arstechnica.com/security/2024/09/massive-china-state-iot-botnet-went-undetected-for-four-years-until-now/3/

and that referenced a 2016 article which mentioned telnet and busybox

https://arstechnica.com/information-technology/2016/10/brace-yourselves-source-code-powering-potent-iot-ddoses-just-went-public/

fortunately, tcl users are less likely to leave their devices in an exploitable _default_ state...

but/however, the vast overwhelming unwashed masses cannot be bothered/troubled to properly operate _mostly_anything_
(just yesterday a tv show spotlighted the massive increase in _distracted_driving_ accidents, especially vehicle-versus-bicyclists-and-pedestrians)

and speaking of danger/peril, Edward Snowden is ABSOLUTELY correct:

https://news.slashdot.org/story/24/09/17/1721229/exploding-pagers-injure-thousands-across-lebanon

see also, exploding icom walkie-talkies:

https://arstechnica.com/security/2024/09/14-dead-as-hezbollah-walkie-talkies-explode-in-second-deadlier-attack/

as always, your mileage may vary

20240919-0218am-cdt-usa-modified: added content and links
« Last Edit: September 19, 2024, 03:18:37 AM by gadget42 »
The fluctuation theorem has long been known for a sudden switch of the Hamiltonian of a classical system Z54 . For a quantum system with a Hamiltonian changing from... https://forum.tinycorelinux.net/index.php/topic,25972.msg166580.html#msg166580

Offline Tambry

  • Newbie
  • *
  • Posts: 4
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #10 on: September 19, 2024, 03:22:58 PM »
my life got very busy lately...but at least I installed Tiny Core on a USB Stick. Attached you see the installation options used - and it boots nicely.
I tried to get all needed info from the 'Book' but i have to confess that it confused me more than it enlightened me. So I now come back with my question:
The installation (as I said: in CLI and without internet) is done by tce-load, right? and I will take the corresponding package (for example 'nano.tcz') from http://tinycorelinux.net/15.x/x86_64/tcz/? How will dependencies be handled?
« Last Edit: September 19, 2024, 03:28:45 PM by Tambry »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #11 on: September 19, 2024, 05:12:31 PM »
Hi Tambry
... The installation (as I said: in CLI and without internet) is done by tce-load, right? ...

Code: [Select]
tce-load -i nanoThis installs nano from your tce/optional directory. That's a copy of nano
that you already downloaded.

Code: [Select]
tce-load -w nanoThis downloads nano from our repository into your tce/optional directory.
You need an internet connection for that.

Code: [Select]
tce-load -wi nanoThis:
1. Downloads nano if it's not present in your tce/optional directory.
2. Installs nano if it's present in your tce/optional directory.
3. Adds  nano.tcz  to your  onboot.lst  file if not already present.

Quote
... How will dependencies be handled?
tce-load resolves dependencies by fetching  ExtensionName.tcz.dep  if it
exists. For each entry in that file, it checks if a  .dep  file exists and then
downloads it. It does the same for all  .dep  files to determine which
extensions need to be downloaded/installed.

Offline Tambry

  • Newbie
  • *
  • Posts: 4
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #12 on: September 22, 2024, 12:47:39 PM »
Hi Rich, thanks for your assistance...
Code: [Select]
tce-load -i nano
...gives "nano.tcz not found!"

Quote
Code: [Select]
tce-load -w nano
...tries to download nano.tcz and then wget complains about a bad address of the repo...obviously because I am in textmode only without internet

Quote
Code: [Select]
tce-load -wi nano
...same as before


I read the instructions twice and still dont know what the tce/optional directory is and what it does.
My aim was just to have a small, text-based Linux installation on a USB drive where I can install the necessary packages, configure the NICs, SAMBA, mdadm and ssh-server :( But the learning curve of TC is massive

    [Edit]: Fixed code tags.  Rich
« Last Edit: September 22, 2024, 01:28:36 PM by Rich »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11675
Re: Help for Newbie: offline installation of tcz packages in texmode
« Reply #13 on: September 22, 2024, 02:13:31 PM »
Hi Tambry
... wget complains about a bad address of the repo...obviously because I am in textmode only without internet ...
Textmode has nothing to do with it.

Check that the repo address is correct:
Code: [Select]
tc@E310:~$ cat /opt/tcemirror
http://repo.tinycorelinux.net/
tc@E310:~$

If it's not, then do this:
Code: [Select]
echo "http://repo.tinycorelinux.net/" > /opt/tcemirror
And run a backup:
Code: [Select]
filetool.sh -b
Next, if your machine has a network connector, get a cable and
connect it to your router. Then reboot:
Code: [Select]
exitcheck.sh reboot
You should now have an internet connection:
Code: [Select]
tc@E310:~$ ifconfig
eth0      Link encap:Ethernet  HWaddr 00:13:20:c4:4a:20 
          inet addr:192.168.1.35  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::213:20ff:fec4:4a20/64 Scope:Link
          inet6 addr: 2600:4040:930f:de00:213:20ff:fec4:4a20/64 Scope:Global
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:7653910 errors:0 dropped:2 overruns:0 frame:0
          TX packets:5420023 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:935731320 (892.3 MiB)  TX bytes:1132410628 (1.0 GiB)

lo        Link encap:Local Loopback 
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:157 errors:0 dropped:0 overruns:0 frame:0
          TX packets:157 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:16921 (16.5 KiB)  TX bytes:16921 (16.5 KiB)

tc@E310:~$
If you see  Bcast  your network card is running:
Quote
inet addr:192.168.1.35  Bcast:192.168.1.255  Mask:255.255.255.0

You should now be able to install nano.

I just reviewed your original post:
... This lead me to Tiny Core and I can install it with the Core Plus CD, use the GUI, enable my USB-WiFi and download and install all needed packages. This showed me that TC can run on the NAS. ...
If you had things working, that is where you should start.

Quote
... To learn, I would like to repeat the installation but with no GUI and no Internet  (ie not using the Appbrowser). ...
Those are 2 different things:
The  Apps  browser is basically a GUI wrapped around  tce-load.
An Internet connection is required regardless of whether you use Apps or tce-load.

Quote
... How/Where can I download the required tcz files from the repository? Can I then just put them on a USB disk, mount it and install with tce-load from it?
If you had CorePlus running on your NAS, you could install  tc-install-GUI.tcz  and
use that to install a text only version to a USB drive. See here:
http://tinycorelinux.net/install.html#5_

You should select  Core Only  and check all 3 boxes under  Wireless.