Find name of machine on which I've connected via ssh - unix

I've ssh'd into one of my school's computer clusters. I'd like to know the name of the machine on which I'm running, e.g. myth14.

The hostname command will do this.

Related

When running a public Jupyter server, what IP do you use?

After you run jupyter notebook on a public server, it will output the following code as far as URL's go:
https://[all ip addresses on your system]:8894/
So, my question is: What URL do I enter into insert web browser here in order to get it running?
You'll need to find the IP address/(domain name if your machine has one) of your specific computer. If you're running Unix you can run ifconfig to get the IP address, if you're running Windows you can run ipconfig instead.

How to use Vim to edit files using SCP but across different Subnets?

I'm learning about Networks and recently found out that the SCP protocol is used to edit files on some other computer. Now the thing is that the other computer should be on the same network. So I was curious about how to edit files across different networks?
Additional information: In my college we have computer labs. Each lab has exactly one switch. All the computers in a particular lab are connected to the switch. Also all of the labs have Internet connection. So if I want to edit a file using VIM on a computer that my friend is on but he is on a different lab, then how can I do it?
Application-level protocols like SSH and HTTP use an underlying TCP/IP connection; they work regardless of the subnet (barring extended networking features like firewalls, packet filters, network proxies, etc.)
So, if your friend's computer is reachable via the Internet, or just the local lab network, and you have the IP address / DNS name of his computer, and the corresponding port (22 for SSH / SCP) is not blocked, and you have a login on his computer, you can remotely edit files there.
If your end goal is remote editing, I would approach this via these steps, each building on top of the previous one:
ping othercomputer
ssh user#othercomputer
In Vim: :edit scp://user#othercomputer/path/to/file

way to detect list of changes in ip address in client machine

Ours is a small network consisting of 15 users. We have LAN messenger installed in every machine. Someone is misusing it by using anonymous IP address in their system. We traced the anonymous IP as 192.168.0.155. Now we want to check each system if they have manually changed their IP to the above address. Does Windows stores IP address change event anywhere? All are static IP within a LAN.
With some luck, I've got an easy solution for you to retrieve some information about the target. You could try to use the nbtstat-command.
Just open a command prompt and type in the following:
nbtstat -A 192.168.0.155
This will output a bunch of information about the target host, including the machinename and MAC address.
Here is an example, how the output could look like:
(source: onlinecomputertips.com)
Good luck

basic how-to-use of SSH

This is pretty embarrassing, but I'm completely new to and know nothing about SSH other than that it's used to connect to a server remotely.
I'm given the following information:
HostName somename(from local network) or some.ip.add.ress(for connecting from outside network)
Port 12345
User someusername
identityfile ~/.ssh/someidfile
in case of ssh-ing to server other than somename (above),
ProxyCommand ssh -W %h:%p name#address
So let's say I want to ssh to that server remotely.
Do I need them to make me an account to be able to do so?
Also, supposing that I ssh from the outside network, what would be the exact syntax?
Finally, if someone has installed some application on the server, say xcode, do you get to share the application installed once you ssh to the same server?
I know these sound like dumb questions to most of you, but please help me out.
(I'm working on Maverick btw.)
ssh -i /path/to/identityfile -p 12345 someusername#some.ip.add.ress
should work
It seems that you already have account.
No. You cannot share application via SSH

Checking small network in mininet by Opendaylight

I have a question about Checking small network by opendaylight
I am not really sure why I can't accress Opendaylight menu which I created from mininet
I am using windows 7 and VMWare player to run mininet and opendaylight(on Ubuntu).
First, i run Ubuntu to run Opendaylight ( I checked that 120.0.0.1:8080 was working)
Second, I run mininet to get IP address.( i will say "192.168.139.128")
Third, based on IP address , it run two putty to run wireshark and building small network
I used sudo mn --mac --controller=remote, ip=192.168.139.128, port=6633.
It successfully build small network. Because i can check all the node infor by command "nodes" and "dump"
However, when I go back to Ubuntu VM and access Opendaylight by 192.168.139.128:8080 (it is given IP from mininet)
I am sure really sure why this happen. Is there any possible reasons ?
Just in case, if anyone is facing the same issue, change network adapter settings in VMWare to use bridge mode.
From the official page
Important troubleshooting - if you are running VirtualBox on the same
host/desktop where the controller is running, and trying to start the
virtual network on Mininet VM produces this error: "Unable to contact
the remote controller at ...", then the following resolves the
problem:
In VirtualBox, go to File-Preferences-Network and make sure you have at least one interface defined as Host-Only. Lets say its name is
vboxnet0
In VirtualBox - Mininet Vm - Settings - Network, check that the adapter is of type Host only , and is connected to the interface from
item 1 (vboxnet0)
On your host where controller and VirtualBox run, do "ifconfig" command to display all network interfaces on the machine.
Search for the interface as in item 1 (vboxnet0 in our example) Take
the ip address specified there (most probably 192.168.56.1 - default),
and that is the correct remote controller ip address to use when
starting a virtual network in mininet vm as stated in the example
above (--controller=remote,ip=192.168.56.1) .
If you are still not able to connect, you might want to consider temporarily disabling firewall on the host running the controller (on
Linux, for example, iptables -F will do the job)
Sometimes, the way you start the mininet is a problem, it does not give error, but does not connect to the remote server. Here is a wrong
example:
sudo mn --topo=tree,3 --mac --switch=ovsk --controller=remote,
ip=192.168.16.10
Here is the correct example:
sudo mn --topo=tree,3 --mac --switch=ovsk
--controller=remote,ip=192.168.16.10
The difference is the "SPACE" between "remote," and "ip".
Also check if you are VMWare player, at IP use this command
sudo mn --mac --controller=remote,--ip=192.168.139.128 --topo tree,5
and refresh your OpenDay Light Controller.
The easiest way is to install Gnome on your Mininet/ODL virtual machine.
I am using the latest (Helium) ODL release so the GUI of ODL is at http://localhost:8181/dlux/indexh.html
on Helium, ODL run inside your distribution folder with ./bin/karaf command (also install required modules inside karaf with feature:install
Attached is my screenshot: https://pbs.twimg.com/media/B8ZgSA6CMAAzuSf.jpg:large
Start the Opendaylight and install the odl-dlux-core plugin. After that the OpenDaylight UI can be accessed through browser on port 8181. So try http://localhost:8181/index.html and you login using username password admin/admin. You should see your topology show up on the UI.

Resources