Solved

Help with ubuntu on Amazon Web Services

Posted on 2013-06-05
17
719 Views
Last Modified: 2014-11-12
I'm a beginner to Linux (I know windows servers very well) and new to AWS

I have deployed an instance of Ubuntu 12.04 on AWS. I want to deploy this project here https://github.com/xtuple/xtuple

Using SSH I want to install the desktop GUI and I'm using this command
sudo apt-get install ubuntu-desktop

Open in new window


I get the errors in the attached file failed-to-fetch.txt

Also need to know how to connect to the Ubuntu server once the desktop GUI is installed just like I would on a windows server using RDC
failed-to-fetch.txt
0
Comment
Question by:Gerhardpet
  • 10
  • 7
17 Comments
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39222195
In the logs it stated "Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?"

Did you try this?

You can use UltraVNC Viewer for the GUI base and Putty for the CLI.
0
 
LVL 1

Author Comment

by:Gerhardpet
ID: 39222211
When I try apt-get update I get these errors

E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied)
E: Unable to lock directory /var/lib/apt/lists/
E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39222252
0
 
LVL 1

Author Comment

by:Gerhardpet
ID: 39222808
Ok got it to work as per your link and running these commands

sudo apt-get update
and
sudo apt-get upgrade
and then
sudo apt-get install ubuntu-desktop

Now I'm trying to use UltraVNC and can't connect. What port do I have to open? Is there anything else I have to do on the server to allow connecting using UltraVNC viewer?
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39222827
Open port 5900

with ultraVNC Viewer  make sure you put host:port #, as long as your firewall is not blocking you should be okay, which in your case you probably did not configure it yet on the Linux block.


Plus I am going to Test my ultraVNC as well with my Linux Mint 14 box just to make sure. I normally use putty.
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39222901
0
 
LVL 1

Author Comment

by:Gerhardpet
ID: 39223091
I can establish a connection using putty on port 22. I have opened port 5900 on my AWS management console but I don't think that will open the 5900 port on the Ubuntu server as far as I know.

Is the VNC server running by default on the Ubuntu server?

Like I said I'm a beginner at linux. How can I open a port using a command?
0
 
LVL 14

Accepted Solution

by:
comfortjeanius earned 500 total points
ID: 39223146
I had firewall rules on my Linux mint, I just thought of that when I could not Putty to the host.

I has to open a terminal and

Type command  sudo ufw status verbose  or sudo ufw status numbered

-then-

I add this entry in order to access Putty and VNC

Putty  ----> sudo ufw allow in 22
VNC  ------> sudo ufw allow in 5900
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39223156
I did not install vnc server just on my windows 7 box and once I type
sudo ufw allow in 5900 I had no problem; sorry it took me some time to get back with  you I was troubleshooting why I could not remote with VNC from Windows to Linux

Plus I uninstall ssvnc on Linux Mint with sudo apt-get purge ssvnc

to make sure it was not install when remoting to Linux I typed dpkg --get-selections ssvnc

Plus here are some extra commands to your Linux repertoire
0
 
LVL 1

Author Comment

by:Gerhardpet
ID: 39223236
When I typed
sudo ufw status verbose I get Status: inactive

when I typed  
sudo ufw allow in 5900 I get Rules updated and Rules updated (v6)

But it still does not work for me to connect using UltraVNC
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39223244
Are you using UltraVNC viewer on the AWS?

sudo ufw status verbose I get Status: inactive  

This means you firewall on Ubuntu is disabled

if you type grep ^ENABLED /etc/ufw/ufw.conf

do it say yes or no
0
 
LVL 1

Author Comment

by:Gerhardpet
ID: 39223322
I'm using the UltraVNC viewer from my windows 7 machine.

Is the VNC server running on the Ubuntu by default or does it have to be enabled on the server using CLI?

So far I'm no able to connect
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39223375
I just have UtraVNC viewer install and I did not install anything on my Linux box.

Plus on Desktop Sharing Preferences do you have this options checked

Sharing
Allow other users to view your desktop
Allow other users to control your desktop

Security
Require the user to enter this password <type a password for authentication>
Automatically configure UPnP router to open and forward ports.
0
 
LVL 1

Author Comment

by:Gerhardpet
ID: 39223411
Keep in mind that I only have SSH access because my Ubuntu instance is hosted on the Amazon Cloud (AWS). That is why I'm trying to make UltraVNC work.

So for now I can only connect using CLI
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39223524
Maybe your firewall is blocking the connection from windows 7 host to the Ubuntu host that is installed on AWS.


I installed Linux Mint  in virtualbox and configured firewall rules on the host.  I just had to allow the port connection and I am to authenticate. I do not know nothing about AWS, but it have to do something with your connection.  You are able to authenticate thru CLI , but not GUI.

I just configure mine to authenticate with GUI thru UltraVNC and I just have the client viewer installed on Windows 7 host.
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39223570
type this in the terminal vino-preferences and hit Enter

Plus on Desktop Sharing Preferences do you have this options checked

Sharing
Allow other users to view your desktop
Allow other users to control your desktop

Security
Require the user to enter this password <type a password for authentication>
Automatically configure UPnP router to open and forward ports.


then reboot and try again.


Plus I performed this action on my Linux virtual machine

sudo ufw disable

and tried to connect via UltraVNC and I was able to established a connection.
0
 
LVL 1

Author Closing Comment

by:Gerhardpet
ID: 39235323
Thanks for the help!
0

Featured Post

Free Gift Card with Acronis Backup Purchase!

Backup any data in any location: local and remote systems, physical and virtual servers, private and public clouds, Macs and PCs, tablets and mobile devices, & more! For limited time only, buy any Acronis backup products and get a FREE Amazon/Best Buy gift card worth up to $200!

Join & Write a Comment

AWS Glacier is Amazons cheapest storage option and is their answer to a ‘Cold’ storage service.  Customers primarily use this service for archival purposes and storage of infrastructure backups.  Its unlimited storage potential and low storage cost …
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now