Friday, May 17, 2024
 Popular · Latest · Hot · Upcoming
54
rated 0 times [  54] [ 0]  / answers: 1 / hits: 11731  / 1 Year ago, sat, february 25, 2023, 11:29:40

I installed Ubuntu 22.04 on Windows 11 using WSL. I then moved it on another disk with the WSL commands (--export/--import).


After moving it, the default user was root, so I added the below lines in /etc/wsl.conf:


[user]
default=numa

Now in the message which is shown once a day when I start Ubuntu (MOTD I think), I can see this message:


[/etc/update-motd.d/50-landscape-sysinfo: 17: cannot create /var/lib/landscape/landscape-sysinfo.cache: Permission denied]

Although it seems to be no harm, I wonder how can I avoid this.


More From » permissions

 Answers
3

Short answer:


Two options:



  • Recommended:


    sudo apt remove landscape-common
    sudo apt autoremove # Optionally, but recommended so that you can
    confirm the problem is gone after restarting
    rm ~/.motd_shown

    Exit and restart, and the error should no longer appear.



  • Or, if you enable Systemd per this answer, the error shouldn't appear either. However, I don't recommend enabling Systemd just to suppress this error message. That's a lot of overhead if you don't need it for other purposes.




More detail:


Don't worry - This isn't related to you moving the distribution. The problem is there in all 22.04 installations on WSL. Funny I never noticed it until you pointed it out -- That shows just how much attention I pay to the MOTD :-/.


This is reported at the bottom of this Github issue, but it's not related to that particular issue (which was previously, and continues to be, fixed).


The problem here is that the Ubuntu distribution for WSL is based on Ubuntu Server, which includes support for Landscape, a feature for managing servers.


This really isn't applicable to WSL, of course, and probably (I'm guessing here, but I'll try to confirm later) requires Systemd support anyway, which WSL does not have. I have a feeling that there's a Systemd unit that sets up the Landscape directory that isn't getting run on WSL; hence the error.


It's safe to remove this package with the above command, and the error will no longer appear.


[#413] Sunday, February 26, 2023, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
saucdisr

Total Points: 4
Total Questions: 102
Total Answers: 117

Location: Ecuador
Member since Thu, Jun 4, 2020
4 Years ago
saucdisr questions
Tue, May 10, 22, 00:19, 2 Years ago
Fri, Mar 4, 22, 17:31, 2 Years ago
Mon, Jul 4, 22, 13:04, 2 Years ago
Sat, May 28, 22, 08:41, 2 Years ago
Wed, Mar 22, 23, 13:40, 1 Year ago
;