0

Hi I have installed ubuntu from bootable usb. During installation I did not pay attention for Openssh server in software selection screen. however is it possible to reboot from usb to just install openssh only without affecting anything which is already installed and configured? Just like we install feature/server role in windows!!! Thanks. I dont have internet connection in my server yet. thanks.

  • Hi!

    To do this please use sudo tasksel. But before that what is in your sources.list file? Upload it to http://pastebin.com/

    Thanks

    – Armand Bozsik Jan 24 '16 at 08:11
  • Thanks Armand Bozsik. What did you mean by "But before that what is in your sources.list file?". Servers are not accessible now, just asking, If I use 'tasksel' where the oppenssh source will come from? are these packages available in the server repository? – Rafiqul Islam Jan 24 '16 at 09:30
  • No. If you dont have internet connection you should install using apt-cdrom described here

    Then if you successfully told APT to use this source instead of the online ones you can use the usual command to install.

    Please note: the number of packages on a cd-rom are limited due to the size restrictions.

    – Armand Bozsik Jan 24 '16 at 10:16
  • http://ubuntuforums.org/showthread.php?t=1403679 – muru Jan 25 '16 at 13:43

2 Answers2

1

If you have the *.iso of your Ubuntu, then the debian package can be retrieved.

  1. First mount your iso:

    sudo mkdir /media/iso; sudo mount -o loop /path/to/iso /media/iso
    
  2. Now, mount the squash present in the iso:

    sudo mount -o loop /media/iso/casper/filesystem.squashfs /mnt
    
  3. To retrieve your package, you need a tool called dpkg-repack

    dpkg-repack --root=/mnt openssh-server
    
Raphael
  • 8,035
0

Rather, you can download the .deb file on any other machine which is connected to the Internet. Using the following command:

sudo apt-get install download openssh-server

The, install the .deb image on the server using the following command:

sudo dpkg -i /home/himanshu_code/Desktop/ssh.deb