Skip to content

Instantly share code, notes, and snippets.

@symm
Created January 17, 2024 08:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save symm/098f341418acfad981edfe5863ed280b to your computer and use it in GitHub Desktop.
Save symm/098f341418acfad981edfe5863ed280b to your computer and use it in GitHub Desktop.
#!/bin/bash
if [ ! -f /root/slic_table ]; then
cat /sys/firmware/acpi/tables/SLIC > /root/slic_table
echo "Wrote SLIC to /root/slic_table"
fi
UUID=$(dmidecode | grep -A8 'System Information' | grep -i UUID | awk '{print $2}')
SERIAL=$(dmidecode | grep -A8 'System Information' | grep -i 'serial number' | awk '{print$3}')
PRODUCT=$(dmidecode | grep -A8 'System Information' | grep -i "Product Name" | sed "s/^.*Product Name: //")
echo "Add the following config to your VM:"
echo ""
echo "smbios1: uuid=$UUID,manufacturer=Dell_Inc.,product=$PRODUCT,serial=$SERIAL"
echo "args: -acpitable file=/root/slic_table"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment