Skip to content

[Build] Fix the installer conf file location according to the updated onie-mk-demo script #37

Closed
vivekrnv wants to merge 1 commit intomasterfrom
onie_boot_cmdline_fix
Closed

[Build] Fix the installer conf file location according to the updated onie-mk-demo script #37
vivekrnv wants to merge 1 commit intomasterfrom
onie_boot_cmdline_fix

Conversation

@vivekrnv
Copy link
Copy Markdown
Owner

@vivekrnv vivekrnv commented Oct 14, 2022

Signed-off-by: Vivek Reddy Karri [email protected]

Why I did it

*.bin image structure in 202205:

vkarri@19d5638dde2d:/sonic$ ls -l  /tmp/tmp.jyuZXWEkTC/installer/
total 1363776
-rw-r--r-- 1 vkarri dip 1396439962 Oct 13 21:44 fs.zip
-rwxr-xr-x 1 vkarri dip      24419 Oct 13 21:44 install.sh
-rw-r--r-- 1 vkarri dip         45 Oct 13 21:44 machine.conf
-rw-r--r-- 1 vkarri dip       1192 Oct 13 21:44 onie-image-arm64.conf
-rw-r--r-- 1 vkarri dip       1192 Oct 13 21:44 onie-image-armhf.conf
-rw-r--r-- 1 vkarri dip       1402 Oct 13 21:44 onie-image.conf
-rw-r--r-- 1 vkarri dip          0 Oct 13 21:44 platform.conf
drwxr-xr-x 2 vkarri dip      12288 Oct 13 21:44 platforms
-rw-r--r-- 1 vkarri dip        541 Oct 13 21:44 platforms_asic
drwxr-xr-x 2 vkarri dip       4096 Oct 13 21:44 tests

*.bin image structure in master:

vkarri@19d5638dde2d:/sonic$ ls -l  /tmp/tmp.9ibWSipeRw/installer                                            
total 1430908
-rwxr-xr-x 1 vkarri dip      18134 Oct 14 13:16 default_platform.conf
-rw-r--r-- 1 vkarri dip 1465188581 Oct 14 13:16 fs.zip
-rwxr-xr-x 1 vkarri dip       7641 Oct 14 13:16 install.sh
-rw-r--r-- 1 vkarri dip         45 Oct 14 13:16 machine.conf
-rw-r--r-- 1 vkarri dip       1402 Oct 14 13:16 onie-image.conf
-rw-r--r-- 1 vkarri dip          0 Oct 14 13:16 platform.conf
-rw-r--r-- 1 vkarri dip        541 Oct 14 13:16 platforms_asic
-rw-r--r-- 1 vkarri dip       1912 Oct 14 13:16 sharch_body.sh
drwxr-xr-x 2 vkarri dip       4096 Oct 14 13:16 tests
drwxr-xr-x 3 vkarri dip       4096 Oct 14 13:16 x86_64

vkarri@19d5638dde2d:/sonic$ ls -l /tmp/tmp.9ibWSipeRw/installer/x86_64/
total 12
drwxr-xr-x 2 vkarri dip 12288 Oct 14 13:16 platforms

However install.sh which runs on ONiE parition expects the platform specific kernel cmd line conf file under platform/$onie_platform_string file https://github.com/sonic-net/sonic-buildimage/blob/master/installer/install.sh#L102

Thus, any platform which defines and depends on these params might be broken on master label.

How I did it

Since we are already filtering the conf files based on TARGET_PLATFORM in build_image.sh, i've just updated the location to installer/platforms instead of installer/$arch/platforms

How to verify it

Verified on the image after the change:

root@r-bulldog-03:/home/admin# extract=1 bash sonic-mellanox.bin
Verifying image checksum ... OK.
Preparing image archive ... OK.
Image extracted to: /tmp/tmp.EjNyiJewuC
To un-mount the tmpfs when finished type:  umount /tmp/tmp.EjNyiJewuC
root@r-bulldog-03:/home/admin# ls -l /tmp/tmp.EjNyiJewuC/installer/
total 1350164
-rwxr-xr-x 1 7331 dip      18134 Oct 14 23:27 default_platform.conf
-rw-r--r-- 1 7331 dip 1382519075 Oct 14 23:27 fs.zip
-rwxr-xr-x 1 7331 dip       7613 Oct 14 23:27 install.sh
-rw-r--r-- 1 7331 dip         45 Oct 14 23:27 machine.conf
-rw-r--r-- 1 7331 dip       1402 Oct 14 23:27 onie-image.conf
-rw-r--r-- 1 7331 dip          0 Oct 14 23:27 platform.conf
drwxr-xr-x 2 7331 dip       2460 Oct 14 23:27 platforms
-rw-r--r-- 1 7331 dip        541 Oct 14 23:27 platforms_asic
-rw-r--r-- 1 7331 dip       1912 Oct 14 23:27 sharch_body.sh
drwxr-xr-x 2 7331 dip         80 Oct 14 23:27 tests

Install the image and check if the cmdline has the parameters for a specific platforms.
For Eg: x86_64-mlnx_msn2100-r0 ONIE_PLATFORM_EXTRA_CMDLINE_LINUX="acpi_enforce_resources=lax acpi=noirq"
https://github.com/sonic-net/sonic-buildimage/blob/master/device/mellanox/x86_64-mlnx_msn2100-r0/installer.conf i.e.

root@r-bulldog-03:/home/admin# sonic-installer install ./sonic-mellanox.bin
..........
root@r-bulldog-03:/home/admin# cat /host/grub/grub.cfg
menuentry 'SONiC-OS-HEAD.1921-c8dcedad3' {
        linux   /image-HEAD.1921-c8dcedad3/boot/vmlinuz-5.10.0-12-2-amd64 root=UUID=5a177dbf-7031-43c2-994d-d3e5e26da35c  rw console=tty0 console=ttyS0,9600n8 quiet intel_idle.max_cstate=0   net.ifnames=0 biosdevname=0                 loop=image-HEAD.1921-c8dcedad3/fs.squashfs loopfstype=squashfs   systemd.unified_cgroup_hierarchy=0                 apparmor=1 security=apparmor varlog_size=4096 usbcore.autosuspend=-1 acpi_enforce_resources=lax acpi=noirq
}

root@r-bulldog-03:/home/admin# reboot 

root@r-bulldog-03:/home/admin# cat /proc/cmdline
BOOT_IMAGE=/image-HEAD.1921-c8dcedad3/boot/vmlinuz-5.10.0-12-2-amd64 root=UUID=5a177dbf-7031-43c2-994d-d3e5e26da35c rw console=tty0 console=ttyS0,9600n8 quiet intel_idle.max_cstate=0 net.ifnames=0 biosdevname=0 loop=image-HEAD.1921-c8dcedad3/fs.squashfs loopfstype=squashfs systemd.unified_cgroup_hierarchy=0 apparmor=1 security=apparmor varlog_size=4096 usbcore.autosuspend=-1 acpi_enforce_resources=lax acpi=noirq

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111
  • 202205

Description for the changelog

Ensure to add label/tag for the feature raised. example - PR#2174 under sonic-utilities repo. where, Generic Config and Update feature has been labelled as GCU.

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

@vivekrnv vivekrnv changed the title [Build] Fix the ONiE installer conf file location according to the update onie-mk-demo script [Build] Fix the installer conf file location according to the update onie-mk-demo script Oct 14, 2022
@vivekrnv vivekrnv changed the title [Build] Fix the installer conf file location according to the update onie-mk-demo script [Build] Fix the installer conf file location according to the updated onie-mk-demo script Oct 14, 2022
@vivekrnv vivekrnv closed this Oct 18, 2022
vivekrnv pushed a commit that referenced this pull request Mar 24, 2025
…lly (sonic-net#639)

#### Why I did it
src/sonic-swss
```
* 4baf54f - (HEAD -> 202412, origin/202412) SRv6: add dscp_mode configuration for MySID entry (#38) (6 hours ago) [mssonicbld]
* ff491ba - [SRv6] Add support for SRv6 VPN (#37) (9 hours ago) [mssonicbld]
```
#### How I did it
#### How to verify it
#### Description for the changelog
vivekrnv pushed a commit that referenced this pull request Mar 24, 2025
… automatically (sonic-net#693)

#### Why I did it
src/sonic-platform-common
```
* 16bb721 - (HEAD -> 202412, origin/202412) [code sync] Merge code from sonic-net/sonic-platform-common:202411 to 202412 (#37) (21 hours ago) [mssonicbld]
```
#### How I did it
#### How to verify it
#### Description for the changelog
vivekrnv pushed a commit that referenced this pull request Mar 24, 2025
…tomatically (sonic-net#887)

#### Why I did it
src/sonic-linux-kernel
```
* 26b1192 - (HEAD -> 202412, origin/HEAD, origin/202412) [code sync] Merge code from sonic-net/sonic-linux-kernel:202411 to 202412 (#37) (21 hours ago) [mssonicbld]
```
#### How I did it
#### How to verify it
#### Description for the changelog
vivekrnv pushed a commit that referenced this pull request Mar 24, 2025
…omatically (sonic-net#909)

#### Why I did it
src/sonic-swss-common
```
* c55ee84 - (HEAD -> 202412, origin/HEAD, origin/202412) [FC] remove FLEX_COUNTER_DELAY_STATUS_FIELD (sonic-net#982) (#37) (22 hours ago) [mssonicbld]
```
#### How I did it
#### How to verify it
#### Description for the changelog
vivekrnv pushed a commit that referenced this pull request Mar 24, 2025
…tically (sonic-net#926)

#### Why I did it
src/sonic-sairedis
```
* a2ee5d6 - (HEAD -> 202412, origin/HEAD, origin/202412) Update build_and_install_module.sh to match newer Linux kernel version (#37) (11 seconds ago) [mssonicbld]
```
#### How I did it
#### How to verify it
#### Description for the changelog
vivekrnv pushed a commit that referenced this pull request Apr 10, 2025
…sonic-net#22170)

#### Why I did it
src/dhcpmon
```
* fb808e0 - (HEAD -> master, origin/master, origin/HEAD) Update key in COUNTERS_DB (#37) (4 days ago) [Yaqiang Zhu]
```
#### How I did it
#### How to verify it
#### Description for the changelog
vivekrnv pushed a commit that referenced this pull request May 6, 2025
…tically (sonic-net#22376)

#### Why I did it
src/sonic-dash-api
```
* 817c0f4 - (HEAD -> master, origin/master, origin/HEAD) Add attributes for FNIC (#37) (27 hours ago) [Lawrence Lee]
```
#### How I did it
#### How to verify it
#### Description for the changelog
vivekrnv pushed a commit that referenced this pull request Oct 21, 2025
Support building under older kernels and newer kernels
liat-grozovik pushed a commit that referenced this pull request Feb 15, 2026
…tomatically (sonic-net#25498)

#### Why I did it
src/sonic-platform-pde
```
* 6e36a87 - (HEAD -> master, origin/master, origin/HEAD) Merge pull request #37 from rustiqly/add-copilot-instructions (11 hours ago) [rustiqly]
* 4fd3ff9 - Add .github/copilot-instructions.md for AI-assisted development (3 days ago) [Rustiqly]
```
#### How I did it
#### How to verify it
#### Description for the changelog
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants