Recover Windows Subsystem Root User Password for Linux - linux

I use linux bash on my windows machine with developer mode windows subsystem setup for linux. I followed this guide to install and configure sudo: https://linuxhint.com/run-sudo-command-windows/ but I forgot my password and I don't know how to reset it. Since I don't use a GUI distribution of ubuntu I can't use the LIVE CD nor can I use the GRUP bootloader. What options do I have?

Related

Is it possible to execute sh files GUI application from linux remote server and view it on local machine?

I have a job that runs denodo platform on remote server. Sh files is a GUI application, and I have to run it to start denodo service. I can't access it in windows, is there a way to solve these problems?
Already running sh files on Putty Windows, but only return null.
If it's a linux GUI application, you should "export display" to view the server screen on your workstation.
Depending of your workstation linux distribution, it might be as easy as :
xhost +<IP_address_of_workstation>
./runMyApp.sh
As your workstation is running windows operating system, you have do further configuration :
https://superuser.com/questions/325630/how-can-i-export-display-from-a-linux-terminal-to-a-windows-pc
https://seanthegeek.net/234/graphical-linux-applications-bash-ubuntu-windows/
If your workstation is connected through SSH you need even more configuration as discussed here : https://unix.stackexchange.com/questions/12755/how-to-forward-x-over-ssh-to-run-graphics-applications-remotely
You can run GUI-Applications of remote linux host in a windows client via ssh (putty) with x-forwarding and an installed x-server (xming)
See this question:
https://superuser.com/questions/299158/how-to-make-putty-do-the-equivalent-of-ssh-x

Linux to Windows SCP password-less access

I have a raspberry pi running Linux (Jessie) which takes pictures every hour and is supposed to upload it onto a windows server. I want to set up a password-less SSH access so that I can upload pictures from the raspberry pi to the windows using SCP. Most of the tutorials online deal with copying files from Linux to Linux environments or windows to Linux set-ups. How do I set up password-less access FROM Raspberry pi to Windows? Should I generate key pairs on windows or raspberry pi? I am also having confusion as to where does the public/private keys resides (windows server or Linux client)?
You may install Cygwin on the Windows side, then you will get the environment similar to Linux on Windows. The keys can be generated on the Linux side and copied to the Windows, location is the same as in the Linux (/.ssh).
There are several tutorials on Cygwin with private key authentication, like this one: https://dbaportal.eu/2015/03/06/setup-openssh-cygwin-for-public-key-authentication/
Note that you will probably have to set up proper access rights for .ssh directory in Windows. You may use chmod in the same way as on Linux, set 700 for .ssh directory and 600 for authorized_keys.

Accessing VPS linux hosting like RDP in Windows

Sorry but I'm a newbie in Linux. I have a VPS hosting of CentOS 6. Can I access it like Remote Desktop on windows to see the GUI?
With a hosted Linux machine chances are that id doesn't even have "the GUI" (an X11 server and some GUI environment like KDE or Gnome) installed at all but only supports command line access via ssh.
If you really need GUI instead of command line access then the "classic" option would be VNC. There is a HowTo for this for CentOS at
http://wiki.centos.org/HowTos/VNC-Server
or at
http://www.howtoforge.com/vnc-server-installation-centos-6.5
for example ...

Python Lib to excute remote windows commands from a linux Box without using ssh

This a very basic requirement of our project.
I need to run Windows command from a linux box, without using ssh, as not all the windows boxes have ssh installed by default.
I was searching for some python libs that can do this work?
Links, tutorial, are highly appreciated.
Some alternatives:
http://www.krenger.ch/blog/wmi-commands-from-linux/
http://pypi.python.org/pypi/WMI/ (under wine or a Windows bridge VM)
https://code.google.com/p/impacket/source/browse/trunk/examples/psexec.py

Installing Virtual PC in Fedora

I currently use a Windows 7 Home Basic. I need to run a certain application, which is, as of now not supported, i.e. compatible with/by W7HB. I tried downloading Virtual PC with XP mode, which does not support W7HB. Hence, I have installed Fedora as a dual boot, as there exists a separate edition of the application for Linux. As I am new to Linux CLI, I would like to install a version of XP in Fedora, i.e. via Virtual XP, assuming it supports. However, I am not able to find any suitable article for the same. Any suggestions...???
The easiest way to do this is to use VirtualBox.
There are 2 options:
run W7HB as the 'host' and install VirtualBox.Then install a guest operating system such as Fedora or WXP inside virtualbox.
OR
run Fedora as the host and install VirtualBox. Then install a guest operating system such as W7HB or WXP.
Be warned that if you install Windows in any form in a virtual machine you will need a Windows installation key. This may require a phone call to Windows support.
There are other solutions - VMWare, KVM, ... but IMHO VirtualBox is the simplest

Resources