Porteus Kernel Builder

Here is a place for your projects which are not officially supported by the Porteus Team. For example: your own kernel patched with extra features; desktops not included in the standard ISO like Gnome; base modules that are different than the standard ISO, etc...
beny
Full of knowledge
Full of knowledge
Posts: 2086
Joined: 02 Jan 2011, 11:33
Location: italy

Porteus Kernel Builder

Post#1456 by beny » 04 Dec 2021, 11:21

hi blaze the script that apply the aufs patch seem that fail so the aufs patch isn't applied you can see also in the kernel source code....maybe i am wrong.

neko
DEV Team
DEV Team
Posts: 2109
Joined: 09 Feb 2013, 09:55
Distribution: APorteus-FVWM-ja-x86_64.iso
Location: japan

Porteus Kernel Builder

Post#1457 by neko » 04 Dec 2021, 12:58

[AUFS ERROR]
Aufs patch AUFS_VERSION "5.15-20211129" for linux-5.15.6
has patching error as followed.

Code: Select all

root /home/guest/kernel/v5.15.6/64/linux-5.15.6 # cat ../../auf/aufs5-standalone.git/aufs5-base.patch | patch -p1
patching file MAINTAINERS
patching file drivers/block/loop.c
Hunk #1 succeeded at 798 (offset -13 lines).
patching file fs/dcache.c
patching file fs/fcntl.c
patching file fs/inode.c
Hunk #1 FAILED at 1782.
1 out of 1 hunk FAILED -- saving rejects to file fs/inode.c.rej
patching file fs/namespace.c
patching file fs/splice.c
patching file fs/sync.c
patching file include/linux/fs.h
Hunk #3 succeeded at 2617 (offset 2 lines).
Hunk #4 succeeded at 2781 (offset 2 lines).
patching file include/linux/lockdep.h
patching file include/linux/mnt_namespace.h
patching file include/linux/splice.h
patching file kernel/locking/lockdep.c
Therefor linux-5.15.6 can not be built with AUFS patch.

linux-5.15.6 without AUFS patch was patched with only one patch for "drivers/staging/r8188eu/os_dep/os_intfs.c".

Code: Select all

# diff ../v5.15.5/64/linux-5.15.5/drivers/staging/r8188eu/os_dep/os_intfs.c 64/linux-5.15.6/drivers/staging/r8188eu/os_dep/os_intfs.c
20d19
< MODULE_FIRMWARE("rtlwifi/rtl8188eufw.bin");
With this OVERLAY-FS kernel, OV.Porteus-XFCE4.12-v5.0rc3-k5.15.6.iso was built.
Please refer to OverlayFS Porteus (Post by neko #85999)


Thanks.

User avatar
babam
Warlord
Warlord
Posts: 526
Joined: 16 Nov 2016, 10:30
Distribution: Porteus 5.0rc3 Xfce K6.1.1
Location: Rainy city

Porteus Kernel Builder

Post#1458 by babam » 13 Dec 2021, 04:13

neko wrote:
22 Nov 2021, 01:53
"Kernel Builder" was updated to version 21.11.22.
(Please refer to the first article of this thread.)

Thanks.

Code: Select all

CONFIG_NTFS3_64BIT_CLUSTER=y --> n
config NTFS3_64BIT_CLUSTER
bool "64 bits per NTFS clusters"
depends on NTFS3_FS && 64BIT
help
Windows implementation of ntfs.sys uses 32 bits per clusters.
If activated 64 bits per clusters you will be able to use 4k cluster
for 16T+ volumes. Windows will not be able to mount such volumes.

It is recommended to say N here.
Thanks.
Sorry, my English is bad.

fulalas
DEV Team
DEV Team
Posts: 2050
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Porteus Kernel Builder

Post#1459 by fulalas » 13 Dec 2021, 09:53

@neko, do you mind setting CONFIG_NVME_HWMON to y?

Source: https://www.phoronix.com/scan.php?page= ... ON-Support

Also, I'm not sure if this is a kernel thing but do you guys know if there's a way to read system fans? I tried sensors, but it only gives me some system temperature readings.

Thanks!

neko
DEV Team
DEV Team
Posts: 2109
Joined: 09 Feb 2013, 09:55
Distribution: APorteus-FVWM-ja-x86_64.iso
Location: japan

Porteus Kernel Builder

Post#1460 by neko » 13 Dec 2021, 11:13

"Kernel Builder" was updated to version 21.12.11. (Please refer to the first article of this thread.)

[Firmware database : kernel-firmware-20211112_150c19f-noarch-1plus.xzm]
that was created with
slackware package "kernel-firmware-20211123_b0e898f-noarch-1.txz" and following arcklinux pakages.
alsa-firmware-1.2.4-noarch-2
archboot-linux-firmware-20211027.1d00989-noarch-3
ipw2100-fw-1.3-noarch-10
ipw2200-fw-3.1-noarch-8
linux-atm-2.5.2-x86_64-7
linux-firmware-20211027.1d00989-noarch-1
nvidia-utils-495.44-x86_64-6
sof-firmware-1.9.2-x86_64-1
wireless-regdb-2021.08.28-noarch-1

New APorteus example ISOs were built with Kernel version 5.16-rc5 including AUFS patch.
They can be used as the most recent "Kernel Builder" engin.
Please refer to ArchLinux packages manager for Porteus (Post by neko #36689)

------------------------
@babam
Thank you for your suggestion.
At next "Kernel Builder" updating, "NTFS3_64BIT_CLUSTER" will be set N in 64bit config of v5.15/v5.16.


-------------------------------------------------
@fulalas
When I introduce new kernel version line,
new paramater, almost all are set N.
The reason is to avoide kernel size bigger.
I don't have special skill for kernel.

Therefor I don't have an opinion about CONFIG_NVME_HWMON.


Thanks.

beny
Full of knowledge
Full of knowledge
Posts: 2086
Joined: 02 Jan 2011, 11:33
Location: italy

Porteus Kernel Builder

Post#1461 by beny » 13 Dec 2021, 12:01


fulalas
DEV Team
DEV Team
Posts: 2050
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Porteus Kernel Builder

Post#1462 by fulalas » 13 Dec 2021, 21:02

@neko, I understand what you mean. It's nice to have a minimalist approach indeed. But we have to think about what we want to drop and nvme temperature doesn't seem something we should drop, especially because it's too simple and should not increase kernel size at all :)

@beny, I've been there before! Unfortunately, calling 'sensors' on my machine returns only this (kernel 5.12.14):

Code: Select all

acpitz-acpi-0
Adapter: ACPI interface
temp1:        +27.8°C  (crit = +105.0°C)

coretemp-isa-0000
Adapter: ISA adapter
Package id 0:  +42.0°C  (high = +80.0°C, crit = +100.0°C)
Core 0:        +38.0°C  (high = +80.0°C, crit = +100.0°C)
Core 1:        +39.0°C  (high = +80.0°C, crit = +100.0°C)
Core 2:        +38.0°C  (high = +80.0°C, crit = +100.0°C)
Core 3:        +39.0°C  (high = +80.0°C, crit = +100.0°C)

beny
Full of knowledge
Full of knowledge
Posts: 2086
Joined: 02 Jan 2011, 11:33
Location: italy

Porteus Kernel Builder

Post#1463 by beny » 13 Dec 2021, 21:50

hi fulalas i think you have the slackware package installed? http://slackware.uk/slackware/slackware ... ware64/ap/ in mine hardware is:
bash-5.1# sensors
nouveau-pci-0100
Adapter: PCI adapter
GPU core: 975.00 mV (min = +0.84 V, max = +1.16 V)
temp1: +35.0°C (high = +95.0°C, hyst = +3.0°C)
(crit = +105.0°C, hyst = +5.0°C)
(emerg = +135.0°C, hyst = +5.0°C)

fam15h_power-pci-00c4
Adapter: PCI adapter
power1: 13.04 W (crit = 94.99 W)

k10temp-pci-00c3
Adapter: PCI adapter
temp1: +16.5°C (high = +70.0°C)

bash-5.1#
but is an old motherboard with a FX6300

fulalas
DEV Team
DEV Team
Posts: 2050
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Porteus Kernel Builder

Post#1464 by fulalas » 14 Dec 2021, 03:49

@beny, Porteus already comes with lm_sensors package. But it seems you're not seeing any fan information either :(

fulalas
DEV Team
DEV Team
Posts: 2050
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Porteus Kernel Builder

Post#1465 by fulalas » 14 Dec 2021, 10:41

I'm trying to create a simpler version (without UI) of neko's application. I have some questions.

1- how do I build and apply AUFS?
2- what's this 'org' thing?
3- what should I put in the .config file so it builds just for my machine?
4- should I apply Arch's firmware patch? Why? How?
5- Does Porteus official kernels come with this firmware patch?

This is the code I have so far. It's building the kernel but I don't know anything about AUFS so it's failing at its first make command (at the end of the script):

Code: Select all

#!/bin/sh
kernelVersion=$1

# Download and extract kernel
kernelMajorVersion=${kernelVersion:0:1}
if [ ! -f linux-$kernelVersion.tar.xz ]; then
	wget https://mirrors.edge.kernel.org/pub/linux/kernel/v$kernelMajorVersion.x/linux-$kernelVersion.tar.xz
fi
tar xvf linux-$kernelVersion.tar.xz

# Copy user config file
cp user.config linux-$kernelVersion/.config

# Build kernel
cd linux-$kernelVersion
cpuThreads=$(grep -c ^processor /proc/cpuinfo)
make -j$cpuThreads
cp arch/x86/boot/bzImage ../vmlinuz
make -j$cpuThreads modules_install INSTALL_MOD_PATH=../
make -j$cpuThreads firmware_install INSTALL_MOD_PATH=../ 2>/dev/null
make -j$cpuThreads O=../kernel-header-$kernelVersion headers_install

# Create symlinks
cd ..
dir=$(/bin/ls lib/modules/)
rm lib/modules/$dir/build lib/modules/$dir/source
ln -sf /usr/src/linux lib/modules/$dir/build
ln -sf /usr/src/linux lib/modules/$dir/source

# Download AUFS
git clone https://github.com/sfjro/aufs5-standalone.git
cd aufs5-standalone
git checkout origin/aufs5.x-rcN

# Copy aufs_type.h
cp -f include/uapi/linux/aufs_type.h ../kernel-header-$kernelVersion/usr/include/linux
cp -f include/uapi/linux/aufs_type.h ../linux-$kernelVersion/usr/include/linux/

# Remove files that will be re-created by the patch
rm -fr fs
rm -fr include
rm -fr Documentation

# AUFS patch
cp ../aufs.patch .
cd ../linux-$kernelVersion
cp -r ../aufs5-standalone/* .
patch -p1 < aufs.patch

if [ ! -d usr/include/linux ]; then
	mkdir -p usr/include/linux
fi

aufsVersion=$(grep VERSION ../kernel-header-$kernelVersion/usr/include/linux/aufs_type.h | cut -d'"' -f2)
util=aufs-util-$aufsVersion-x86_64

make -j$cpuThreads
make -j$cpuThreads install DESTdir=../$util
That's the error:

Code: Select all

Makefile:11: could not find kernel config file. internal auto-config may fail
config.mk:57: CONFIG_AUFS_SBILIST is enabled but CONFIG_AUFS_MAGIC_SYSRQ nor CONFIG_PROC_FS
make: *** No rule to make target '/lib/modules/5.12.14-porteus/build/scripts/headers_install.sh', needed by 'usr/include/linux/aufs_type.h'.  Stop.
make: *** Waiting for unfinished jobs....
-I/home/guest/kernel/5.12.14/linux-5.12.14/include -DCONFIG_AUFS_FS_MODULE -UCONFIG_AUFS -DCONFIG_AUFS_BRANCH_MAX_127 -DCONFIG_AUFS_SBILIST -DCONFIG_AUFS_DEBUG
make -C /lib/modules/5.12.14-porteus/build M=/home/guest/kernel/5.12.14/linux-5.12.14/fs/aufs EXTRA_CFLAGS="-I/home/guest/kernel/5.12.14/linux-5.12.14/include -DCONFIG_AUFS_FS_MODULE -UCONFIG_AUFS -DCONFIG_AUFS_BRANCH_MAX_127 -DCONFIG_AUFS_SBILIST -DCONFIG_AUFS_DEBUG" modules
make[1]: *** /lib/modules/5.12.14-porteus/build: No such file or directory.  Stop.
make: *** [Makefile:43: fs/aufs/aufs.ko] Error 2

Why is it looking of the absolute path '/lib/modules/5.12.14-porteus/build/scripts/headers_install.sh' instead of the relative one?

beny
Full of knowledge
Full of knowledge
Posts: 2086
Joined: 02 Jan 2011, 11:33
Location: italy

Porteus Kernel Builder

Post#1466 by beny » 14 Dec 2021, 11:05

hi fulalas you are right no fan detected
# pwmconfig version 3.6.0
This program will search your sensors for pulse width modulation (pwm)
controls, and test each one to see if it controls a fan on
your motherboard. Note that many motherboards do not have pwm
circuitry installed, even if your sensor chip supports pwm.

We will attempt to briefly stop each fan using the pwm controls.
The program will attempt to restore each fan to full speed
after testing. However, it is ** very important ** that you
physically verify that the fans have been to full speed
after the program has completed.

/usr/sbin/pwmconfig: There are no fan-capable sensor modules installed
bash-5.1#
pwmconfig is part of lm-sensors seem

neko
DEV Team
DEV Team
Posts: 2109
Joined: 09 Feb 2013, 09:55
Distribution: APorteus-FVWM-ja-x86_64.iso
Location: japan

Porteus Kernel Builder

Post#1467 by neko » 14 Dec 2021, 13:41

@babam, @fulalas

==Current==
[CONFIG_NTFS3_64BIT_CLUSTER]

Code: Select all

# grep CONFIG_NTFS3_64BIT_CLUSTER v*/*.config
v5.15.8/64bit.config:CONFIG_NTFS3_64BIT_CLUSTER=y
v5.16-rc5/64bit.config:CONFIG_NTFS3_64BIT_CLUSTER=y
#
[CONFIG_NVME_HWMON]

Code: Select all

# grep CONFIG_NVME_HWMON v*/*.config
v5.10.84/32bit.config:# CONFIG_NVME_HWMON is not set
v5.10.84/64bit.config:# CONFIG_NVME_HWMON is not set
v5.14.21/32bit.config:# CONFIG_NVME_HWMON is not set
v5.14.21/64bit.config:# CONFIG_NVME_HWMON is not set
v5.15.8/32bit.config:# CONFIG_NVME_HWMON is not set
v5.15.8/64bit.config:# CONFIG_NVME_HWMON is not set
v5.16-rc5/32bit.config:# CONFIG_NVME_HWMON is not set
v5.16-rc5/64bit.config:# CONFIG_NVME_HWMON is not set
#
The latest stable 5.14 version of the Linux kernel is 5.14.21 (EOL).
AUFS patch for v5.10; "5.10-20211018" has a patching error.
AUFS patch for v5.15; "5.15-20211129" has a patching error.

Therefore the config of only 5.16 is updated.
(The config of 5.10/5.15 will be updated when AUFS patch will be fixed.)

Kernel 5.15.8 64bit.config was updated by the command "make menuconfig";
-> File systems -> DOS/FAT/EXFAT/NT Filesystems -> NTFS Read-Write file system support
Set "64 bits per NTFS clusters" No.
-> Device Drivers -> NVME Support
Set "NVMe hardware monitoring" Yes.

And then using this config 64bit kernel 5.15.8 was built without AUFS patch.
For Example Porteus-XFCE4.12-v5.0rc3 was built with this OverlayFS kernel 5.15.8.
Refer to OverlayFS Porteus (Post by neko #86138)


-----------------------------
"Kernel Builder" was updated to version 21.12.14. (Please refer to the first article of this thread.)

Kernel 5.16 configs were updated.


Thanks.

beny
Full of knowledge
Full of knowledge
Posts: 2086
Joined: 02 Jan 2011, 11:33
Location: italy

Porteus Kernel Builder

Post#1468 by beny » 14 Dec 2021, 16:15

hi fulalas this is the log..when i have loaded the driver for the fan control in kernel modprobe nct6775
Linux home.giulio.home 5.15.8-beny #1 SMP Tue Dec 14 15:47:40 CET 2021 x86_64 AMD FX(tm)-6300 Six-Core Processor AuthenticAMD GNU/Linux

bash-5.1# sensors
nouveau-pci-0100
Adapter: PCI adapter
GPU core: 975.00 mV (min = +0.84 V, max = +1.16 V)
temp1: +36.0°C (high = +95.0°C, hyst = +3.0°C)
(crit = +105.0°C, hyst = +5.0°C)
(emerg = +135.0°C, hyst = +5.0°C)

fam15h_power-pci-00c4
Adapter: PCI adapter
power1: 13.04 W (crit = 94.99 W)

nct6776-isa-0290
Adapter: ISA adapter
Vcore: 1.20 V (min = +0.00 V, max = +1.74 V)
in1: 1.86 V (min = +0.00 V, max = +0.00 V) ALARM
AVCC: 3.36 V (min = +0.00 V, max = +0.00 V) ALARM
+3.3V: 3.34 V (min = +0.00 V, max = +0.00 V) ALARM
in4: 88.00 mV (min = +0.00 V, max = +0.00 V) ALARM
in5: 1.66 V (min = +0.00 V, max = +0.00 V) ALARM
in6: 88.00 mV (min = +0.00 V, max = +0.00 V) ALARM
3VSB: 3.46 V (min = +0.00 V, max = +0.00 V) ALARM
Vbat: 3.36 V (min = +0.00 V, max = +0.00 V) ALARM
fan1: 0 RPM (min = 0 RPM)
fan2: 2601 RPM (min = 0 RPM)
fan3: 1388 RPM (min = 0 RPM)
SYSTIN: +32.0°C (high = +0.0°C, hyst = +0.0°C) ALARM sensor = thermistor
CPUTIN: +32.5°C (high = +80.0°C, hyst = +75.0°C) sensor = thermistor
AUXTIN: +127.5°C (high = +101.0°C, hyst = +101.0°C) ALARM sensor = thermistor
PCH_CHIP_TEMP: +0.0°C
PCH_CPU_TEMP: +0.0°C
PCH_MCH_TEMP: +0.0°C
intrusion0: ALARM
intrusion1: ALARM
beep_enable: disabled

k10temp-pci-00c3
Adapter: PCI adapter
temp1: +15.9°C (high = +70.0°C)

fulalas
DEV Team
DEV Team
Posts: 2050
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Porteus Kernel Builder

Post#1469 by fulalas » 14 Dec 2021, 20:12

@neko, exactly. You just need to set CONFIG_NVME_HWMON to y :)

@beny, nice! What's the step by step to load this driver? :)

fulalas
DEV Team
DEV Team
Posts: 2050
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Porteus Kernel Builder

Post#1470 by fulalas » 15 Dec 2021, 03:47

@neko, why kernel 5.12.14 is not showing in you application?

Thanks! :)

Post Reply