Remote desktop: Ubuntu 12.04 from Windows 7 - remote-desktop

I want to share(and give control of) my Ubuntu 12.04 desktop to my brother(using Windows 7).
We are not on the same network. (We're in different cities).
What would be the easiest way to accomplish this (without compromising security)?
I read that VNC isn't very secure.
Thanks.

I would try Teamviewer. Nice tool, i've often used it private and at work to remote access PCs. With Teamviewer it's also possible to access clients via Android/IPhone.

You can also user UltraVNC. It works good with Windows-Linux remote desktop. UltraVNC

Related

How to synchronize code files on windows with WSL/linux?

Basically I have some C/C++ code that I need to build and debug on a Linux machine. Unfortunately, my windows laptop doesn't have enough free hard space to install some Linux dist nor does it have enough free RAM to comfortably run VM.
Until now, I dealt with it rather comfortably using WSL, but the scale was rather small. It was easy to edit and debug 2-3 .c files through CLI and gdb, but it became really annoying on a large scale projects.
I want something simple as "edit code in windows IDE [X], compile it on remote Linux/WSL (the project uses Makefiles), and preferably debug it via gdb".
VS has something close to what I want, but it can't deal with existing Linux projects. It needs to create a new configuration which is alien to the project's Makefile.
I know this question is a bit old, but I think the solution is to make a symlink between your WSL folder and the Window's folder. This is how I handled it for a Ubuntu-20.04 WSL:
Access PowerShell in Administrator mode
Type cmd.exe in the PowerShell
Once cmd.exe is opened, type mklink /d C:\<path_to_your_Windows_folder> \\wsl$\Ubuntu-20.04\home\<your_user>\<path_to_your_WSL_folder>
EDIT
This was tested under Windows 10 Version 2004 with WSL2
I'm unsure about C and C++ but it sounds like this is exactly the same as how i work in node and javascript every day.
I checkout my code using git inside WSL to a location like /mnt/c/code/myproject. Then using sublime/VS code/webstorm i edit the files in windows in the location c:\code\myproject this works really well and have been doing this every day for over a year.
Things to be aware of are that you need to ensure that your editor of choice saves files with linux line endings and that all command line operations are done inside WSL.
Please see this article to see the differences between windows and linux files and how this works inside the WSL.
I want something simple as "edit code in windows IDE , compile it on remote linux/WSL
You will have something as simple as that.
Only with Windows 19.03 though:
See "Updated WSL in Windows 10 version 1903 lets you access Linux files from Windows"
Microsoft's Craig Loewen says:
In the past, creating and changing Linux files from Windows resulted in losing files or corrupting data. Making this possible has been a highly requested and long anticipated feature. We're proud to announce you can now easily access all the files in your Linux distros from Windows.
So how does this work? He goes on to explain:
To put it briefly: a 9P protocol file server facilitates file related requests, with Windows acting as the client.
We've modified the WSL init daemon to include a 9P server. This server contains protocols that support Linux metadata, including permissions.
There is a Windows service and driver that acts as the client and talks to the 9P server (which is running inside of a WSL instance).
Client and server communicate over AF_UNIX sockets, since WSL allows interop between a Windows application and a Linux application using AF_UNIX as described in this post.
Warning:
The old rules still apply, you should NOT access your Linux files inside of the AppData folder!
If you try to access your Linux files through your AppData folder, you are bypassing using the 9P server, which means that you will not have access to your Linux files, and you could possibly corrupt your Linux distro.

How to transfer a file from Windows XP to a virtual machine inside vSphere 5.5?

I have a file on my desktop that I need to put onto one of the virtual machines, however when I search for solutions on how to do this many say to download third party software to do it, or to use drag and drop through vSphere. The issue is I am on a restricted network and can't install additional software, and also don't have the drag an drop functionality in vSphere.
I have seen it done in the past using the command line and the IP address of the machine I want to send it to, along with the username and password, however I can't remember the syntax. Can anyone provide instruction on what to type into the terminal to do this?
Have you given the Copy-VMGuestFile cmdlet a look from PowerCLI?
http://www.vmware.com/support/developer/PowerCLI/PowerCLI651/html/Copy-VMGuestFile.html
If you're not a fan of PowerShell, there's a couple SDK options you could use with the vSphere Web Services API. Specifically, you're looking for the GuestFileManager object and the InitiateFileTransferToGuest method: http://pubs.vmware.com/vsphere-5-5/topic/com.vmware.wssdk.apiref.doc/vim.vm.guest.FileManager.html

How to easily transfer qpython scripts from windows to android for development?

while developing qpython scripts, it would be much easier to develop them on a pc and only transfer them to the android device for testing.
What is the easiest way to do such a transfer? (Development might require to do this very frequently)
Thanks in advance for all your feedback.
tfv
In linux with ADB installed, in terminal you can use
adb push pcprojectfolder /sdcard/com.hipipal.qpyplus/projects/androidprojectfolder
You do need to manually end the task on the phone before pushing though.
There is a ftp service in setting part which can help you to translate files between android device and pc.
QPy for android has built in FTP. Just enter the local address it provides into an ftp program (like bareftp for ubuntu)

Enumerate logon sessions remotely

I want to enumerate logon sessions on a remote host (citrix terminal server). What I found so far is LsaEnumerateLogonSessions() / LsaGetLogonSessionData(), but you can't call it remotely.
I read some docs about RPC, but if I understood it right, you need an extra application on the remote host that executes your functions (that's something I want to avoid).
Is there a way to implement such a thing? Maybe with the remote desktop api?
Another solution I found: http://msdn.microsoft.com/en-us/library/windows/desktop/aa370669%28v=vs.85%29.aspx
Other options include the WTS APIs: WTSEnumerateSessionsEx. If you want to be Citrix specific you can also use the XenApp PowerShell SDK.
Use Win32_LogonSession, it is possible to call WMI from a remote computer.

Using Xnest between Mac OS X (Snow Leopard) and Ubuntu 10.10

I just installed an Ubuntu 10.10 desktop on a system to do some development work. I would like to run the X server environment on my MacBook instead of keyboard hopping (the graphics system on the Ubuntu box is not so great).
Poking around on the web I uncovered the following command that I can run from a terminal in Mac OS X:
/usr/X11/bin/Xnest -geometry 1280x900 :1 & DISPLAY=:1 ssh -X -Y grog#ubuntusys gnome-session
Note I have ssh set up so authentication happens automatically.
This seems to work great -- the Ubuntu desktop appears on my Mac OS X screen! (It seems to be smart enough to start X11 if it isn't running already). However if I try to open any program, it dies out. So close.
Any suggestions appreciated.
Update: Thanks to the answer below that provides a tutorial link I learned how to do basic X forwarding. You can do this from an X terminal window on the Mac simply like this:
ssh -X -Y username#targetsystem
then you can start X applications that run on the remote system but their windows are on the Mac X server. The issue that I now have is I want to start the gnome desktop session:
gnome-session
but the problem there is that the session takes over the whole Mac desktop. You cannot resize it or move it. Worse, the top part of the windows managed by the window manager end up underneath the menu bar that Mac OS puts up there so you cannot access those controls. I think this is a problem that Xnest was intended to solve, or am I misunderstanding what it is all about?
Use Xnest or Xephyr this way on your Mac OS X:
Xnest :1 -geometry 1280x800 -query 10.0.1.x
Xephyr :1 -screen 1280x1024 -query 192.168.1.x
The only thing you have to do is to enable remote login in your Linux by manually editing /etc/gdm/custom.cfg or using the gdmsetup GUI program. Here CentOS 5 is taken as an example. In Ubuntu things will be a little differrent.
This approach is very different to VNC which is like Microsoft's RDP (screen capture) while XDMCP utilizes the graphic power of your Mac to assist Linux system.
Remember that X11 was specifically designed to be used over network connections rather than on an integral or attached display device. X features network transparency: the machine where an application (the client application, for instance Firefox on Linux) runs can differ from the user's local machine (the display server, that is the X11 on your Mac). This approach allows both 2D and 3D operations to be fully accelerated on the user's local X server.
Depending on which version of OSX you're running, the best bet is probably the native Mac X11 Distribution. It's on the install CD (or if you're like me you got Lion through the App Store, it is available in the Utilities folder by default).
Launching it (Applications > Utilities > X11) brings up a specific X11 x-terminal, which you can use to ssh forward over to your Ubuntu system. That link in Answer 1 is pretty old, I found this one to be more helpful: http://www.craigryder.com/linux-ubuntudebetc/x11-forwarding-and-ssh-for-remote-linux-ubuntu-desktop/
The only extra option I use is the -C flag to enable compression when I run my ssh command. Please note that you do NOT have to run a full gnome-session to use the X features - you can simply run the program you want (ie, $ gedit&). This gets you out of using the whole desktop, but it is kind of weird since your Mac desktop still gets blacked out. You can find more on this technique # http://ubuntuforums.org/showthread.php?t=1373823&page=2
I also noticed that on 10.10 Ubuntu, my system showed the same odd UI control behaviors you mention, but those disappeared when I upgraded my distribution to Ubuntu 11. I didn't really go to deep to see if simply upgrading X to the latest version on the 10.10 Ubuntu system would have fixed that issue, but I can confirm that it does not appear in 11.
One final note, this still seems to force the Mac X11 server into Full-Screen mode, but if you press COMMAND-ALT-A it immediately takes you out of the X desktop and back into your Lion desktop, which allows me to have both running and still be productive when I need to jump out of my Ubuntu system. I seem to be able to always access all the title and menu bars for all of my X apps just as though I was sitting at the Ubuntu desktop.
One caveat - I'm running the above to connect to a VMWare Workstation VM running Ubuntu (with 3D acceleration enabled) on my workstation - connecting to actual hardware may (though I can't fathom how) result in slightly different behavior.
Hope this helped!
Is VNC not working for you?
Or regular X forwarding over SSH.

Resources