VMware vSphere

 View Only
Expand all | Collapse all

software-packages

  • 1.  software-packages

    Posted Aug 16, 2018 07:24 AM

    Author : Chris Bedford

    URL : http:////docs.vmware.com/en/VMware-vSphere/6.0/com.vmware.vsphere.upgrade.doc/GUID-5FCA78EC-8637-43A4-8B28-24624E4D5EBA.html

    Topic Name : Install vCenter Server Appliance Patches

    Publication Name : vSphere Upgrade

    Product/Version : VMware vSphere/6.0

    Question :

    how to download the software-packages utility



  • 2.  RE: software-packages

    Posted Aug 16, 2018 08:01 AM

    Software-packages  utility is embedded with vCSA. You don't have to download any utility.

    https://www.vladan.fr/patch-vmware-vcenter-server-vcsa/

    Putty into appliance shell and you will be able to patch using vCSA

    Please consider marking this answer as "correct" or "helpful" if you think your questions have been answered



  • 3.  RE: software-packages

    Posted Aug 16, 2018 08:10 AM

    Well, when I want to check which patches will gets actually installed, the command is not found :

    VMware vCenter Server Appliance 6.5.0.15000

    Type: vCenter Server with an embedded Platform Services Controller

    root@pcoe-vcsa.pcoe.fr's password:
    Last login: Thu Aug 16 07:02:44 2018 from xxx.xxx.xxx.xxx
    root@PCOE-VCSA [ ~ ]# software-packages list –staged
    -bash: software-packages: command not found

    So where is the problem?



  • 4.  RE: software-packages

    Posted Aug 16, 2018 08:12 AM

    You will have to run software-packages from the below shell



  • 5.  RE: software-packages

    Posted Aug 16, 2018 08:13 AM

    Putty into vCSA and run the below command:

    chsh -s /bin/appliancesh root

    Close and re-launch putty to vCSA.



  • 6.  RE: software-packages

    Posted Aug 16, 2018 08:26 AM

    Thanks,

    I can now run the help command

    Command> software-packages -h
    usage: software-packages [-h] {stage,unstage,validate,install,list} ...

    optional arguments:
      -h, --help            show this help message and exit

    sub-commands:
      {stage,unstage,validate,install,list}
        stage               Stage software update packages
        unstage             Purge staged software update packages
        validate            Validate software update packages
        install             Install software update packages
        list                List details of software update packages

    but the one as documented on the site still fails (with double '--' or a single '-') :

    Command> software-packages list --staged

    usage: software-packages [-h] {stage,unstage,validate,install,list} ...

    software-packages: error: unrecognized arguments: –-staged

    Command>

    Command> software-packages list -staged

    usage: software-packages [-h] {stage,unstage,validate,install,list} ...

    software-packages: error: unrecognized arguments: –staged



  • 7.  RE: software-packages

    Posted Aug 16, 2018 08:31 AM

    command looks good to me.

    software-packages list --staged



  • 8.  RE: software-packages

    Posted Aug 16, 2018 08:33 AM

    Alos, can you login to bash shell and run the below command to verify disk utilization.

    df -Th



  • 9.  RE: software-packages

    Posted Aug 16, 2018 08:39 AM

    Well, my problem was probably a typo as I initially copy and paste the command from the site.

    but it not so evident to see:

    So retyping manually 'list --staged' returns a good result.

    Thanks for the help.



  • 10.  RE: software-packages

    Posted Aug 16, 2018 08:45 AM

    Glad I could help!

    software-packages install –iso –accepteulas --> To patch vCSA.



  • 11.  RE: software-packages

    Posted Aug 16, 2018 08:50 AM

    I mark this as 'helpful' only because I don't see it possible to be marked as 'solved' also.



  • 12.  RE: software-packages

    Broadcom Employee
    Posted Aug 24, 2018 09:20 PM

    In summary of the options:

    Pick one of the following:

    • software-packages stage --iso --acceptEulas     stages software packages from ISO and accepts EULA.
    • software-packages stage --url --acceptEulas     stages software packages from the default VMware online repository and accepts EULA.

    Verify that it downloaded correctly:

    • software-packages list --staged      lists the details of the staged software package.

    Install the updates:

    • software-packages install --staged   installs the staged software package.

    Apply the changes:

    • reboot  reboots the VCSA

    Also if like me you had a PSC where the software-packages command was missing try this instead:

    # python /usr/lib/applmgmt/support/scripts/software-packages.py <Then add options>



  • 13.  RE: software-packages

    Posted May 21, 2019 09:55 AM

    Can we do something like this:

    /bin/appliancesh --username root software-packages list on bash shell?

    How does ansible run on appliancesh?



  • 14.  RE: software-packages

    Broadcom Employee
    Posted May 21, 2019 01:24 PM

    Hi Uday,

    The above commands work from the appliance login session when your prompt reads Command>

    As soon as you type shell, you are dropped into an appliancesh session.

    Usually denoted by a:

    root@hostname [ ~ ]#

    from the appliance shell you can get results for software packages by running:

    python /usr/lib/applmgmt/support/scripts/software-packages.py

    Followed by the same command structure; for example:

    I have obscured part of the hostname.

    Could you please clarify what you are attempting to do with ansible?



  • 15.  RE: software-packages

    Posted May 21, 2019 08:50 PM

    Publication Name : vSphere Upgrade Product/Version : VMware vSphere/6.0 Question : how to download the software-packages utility



  • 16.  RE: software-packages

    Posted May 22, 2019 04:06 AM

    Thanks for reply,

    This will help.

    Actually we are writing code to automate the deployment of VMWare vCloud NFV 3.1 with VIO 5.1. We are using pyVmomi sdk and Ansible. Our main focus would be to use Ansible VMware cloud modules. It seems Ansible do not have complete features w.r.t VMware automation. Only vSphere automation is supported as of now and that too only 95%. hence I decided to use pyVmomi wherever Ansible lags.

    We also have to take care of updates and patches and I found this command "software-packages install –iso " but Ansible does not work on "appliancesh".  For other activities I have changed default shell to bash. For command "software-packages install" I wanted to run from bash shell and you helped.

    BR//uday



  • 17.  RE: software-packages

    Posted May 15, 2020 03:08 PM

    Hello,

    I had the same issue where software-packages was an unknown command and this made the trick. So the thread should be marked as answer.

    Thanks a lot Vijay2027

    Jeremy



  • 18.  RE: software-packages

    Posted Nov 18, 2020 06:06 PM

    Thank you for the post for how to get into Appliance Shell.

    After patch is completed, is there a way to change back to regular shell?



  • 19.  RE: software-packages

    Posted May 26, 2021 05:55 PM

    Sorry for the late reply but for anyone digging this thread up, to change back: From Appliance Shell, type shell. Once in Bash, type chsh -s /bin/bash.