Welcome to the Linux Foundation Forum!

When I am trying to fetch the tar file from the lftrainning URL getting 401 unauthorized exception

Hello All,

When I am trying to pass the username and password and then trying to fetch the tar file getting 401 unauthorised exception.

  1. I tried to execute through this command

wget --user=user--password=password "https://cm.lf.training/LFS258/LFS258 V2024-03-14 SOLUTIONS.tar.xz"

  1. I tried even as below as well. As the URL is having spaces added %20 and tried so no luck.

Please help or let me know how I can resolve this.

Regards,
Balaji

Comments

  • fcioanca
    fcioanca Posts: 2,157

    Hi @mandavabalaji9

    Please double check to ensure your pasted command matches the one in the pdf. Per the note under the wget command, you may have to manually add back underscores if they were removed during copy paste.

    You can also retrieve the resources following instructions located in the introductory chapter.

    Regards,
    Flavia
    Linux Foundation Training Team

  • chrispokorni
    chrispokorni Posts: 2,354

    Hi @mandavabalaji9,

    Perhaps the note that follows the command may be of some help. It makes you aware of the possible issue, and it suggests the workaround as well. Adding it below in case your lab guide is missing the note:

    Note: depending on your PDF viewer, if you are cutting and pasting the above instructions, the underscores may disappear and be replaced by spaces, so you may have to edit the command line by hand!

    Regards,
    -Chris

  • mandavabalaji9
    mandavabalaji9 Posts: 2
    edited June 16

    @chrispokorni , @fcioanca - Thanks a lot to both of you. Yes that has resolved my issue and one more small correction. if we declare the command as per below then only it is working hope you can correct in the pdf as well.
    wget --user=xxxx --password=xxxxx "https://cm.lf.training/LFS258/LFS258_V2024-03-14_SOLUTIONS.tar.xz"

    when the same command is executed as mentioned in pdf that is not working where the username and password is passed after the URL.

  • chrispokorni
    chrispokorni Posts: 2,354

    Hi @mandavabalaji9,

    For the majority of learners, the provided syntax works to retrieve the class resources. However, in very few select cases, depending on the local workstation OS and the terminal application settings, the syntax may have to be reversed for the command to work. Please keep this in mind as you make progress through the lab exercises - there will be many cases where commands use flags and options and the syntax may need to be adjusted to work with your environment.

    Regards,
    -Chris

Categories

Upcoming Training