|
| 1 | +# Changing the virtual device |
| 2 | + |
| 3 | +You can control the hw sku and default factory configuration for the VS image |
| 4 | +by modifying the content of the file default_sku in this directory. |
| 5 | + |
| 6 | +The format of default_sku is a single line: |
| 7 | + |
| 8 | +``` |
| 9 | +<hw_key> <default_preset> |
| 10 | +``` |
| 11 | + |
| 12 | +## Allowable values for hw_key |
| 13 | + |
| 14 | +| hw_key | Device | |
| 15 | +| ------ | ------ | |
| 16 | +| Force10-S6000 | Dell Force10 S6000| |
| 17 | +| brcm_gearbox_vs | Similar to Force10-S6000, but implements a virtual BRCM81724 Gearbox Phy | |
| 18 | + |
| 19 | +## Allowable values for default_preset |
| 20 | + |
| 21 | +These include "t1", "l2", and "empty". See the file |
| 22 | +sonic-buildimage/src/sonic-config-engine/config_samples.py for details on how |
| 23 | +each default_preset value is interpreted. |
| 24 | + |
| 25 | +# Changing the hwsku of an existing VS switch |
| 26 | + |
| 27 | +To change the default hwsku for a VS image that has already been built and installed, follow these steps: |
| 28 | + |
| 29 | +- Edit /usr/share/sonic/device/x86_64-kvm_x86_64-r0/default_sku. For details, see the section below (Device Specific Documentation) |
| 30 | +- Edit /etc/sonic/config_db.json, and change the "hwsku" key in DEVICE_METADATA:localhost to match the hw_key used in default_sku. Example: |
| 31 | + |
| 32 | + "DEVICE_METADATA": { |
| 33 | + "localhost": { |
| 34 | + ... |
| 35 | + "hwsku": "brcm_gearbox_vs", |
| 36 | + ... |
| 37 | + } |
| 38 | + }, |
| 39 | + ... |
| 40 | +- Reboot the switch |
| 41 | +- Use "show platform summary" to verify, and follow any steps specific to the platform, as needed, such as those described below for the brcm_gearbox_vs hwsku. |
| 42 | + |
| 43 | +# Device Specific Documentation |
| 44 | + |
| 45 | +For general info on building, see https://github.com/Azure/sonic-buildimage/blob/master/README.md |
| 46 | + |
| 47 | +## Force-10-S6000 |
| 48 | + |
| 49 | +This is the default VS for SONiC. To enable, set contents of default_sku to: |
| 50 | + |
| 51 | +``` |
| 52 | +Force10-S6000 t1 |
| 53 | +``` |
| 54 | + |
| 55 | +To build: |
| 56 | + |
| 57 | +``` |
| 58 | +make init |
| 59 | +make configure PLATFORM=vs |
| 60 | +make target/sonic-vs.img.gz |
| 61 | +``` |
| 62 | + |
| 63 | +## brcm_gearbox_vs |
| 64 | + |
| 65 | +This sku simulates a device with a Broadcom BRCM81724 gearbox PHY. To enable, |
| 66 | +set default_sku to: |
| 67 | + |
| 68 | + |
| 69 | +``` |
| 70 | +brcm_gearbox_vs t1 |
| 71 | +``` |
| 72 | + |
| 73 | +To build (same as Force-10-S6000): |
| 74 | + |
| 75 | +``` |
| 76 | +make init |
| 77 | +make configure PLATFORM=vs |
| 78 | +make target/sonic-vs.img.gz |
| 79 | +``` |
| 80 | + |
| 81 | +To verify, install and bring up SONiC. There will be a new gbsyncd docker |
| 82 | +which is designed to respond to configuration directed towards the gearbox phy |
| 83 | +"switch". swss will create that gearbox switch on startup after detecting the |
| 84 | +gearbox is present (this is done by a short lived gearsyncd that runs in the |
| 85 | +swss docker). |
| 86 | + |
| 87 | +The commands "show gearbox interfaces status" and "show gearbox phys status" can be |
| 88 | +used to verify the virtual gearbox phy has been created. See https://github.com/Azure/sonic-utilities/blob/master/doc/Command-Reference.md#gearbox for details. |
0 commit comments