1 / 3
Caption Text
2 / 3
Caption Two
3 / 3
Caption Three margin testing

Monday, October 12, 2009

Share files between 2 ubuntu computers with SSH

Share files between 2 ubuntu computers « Linux Owns

If you have two computers running Ubuntu on the same network, it could be an good idea to use openssh to share files between them.

The setup shouldn't take more than 2 minutes.

updated for Ibex.

On all the computers you want to share files with copy/paste the following command.

Ubuntu 8.04:

sudo apt-get install openssh-server openssh-client

Ubuntu 8.10:

sudo apt-get install ssh

Then you need to figure out the ip of each the computer you want to connect to.

Most of the time it's something like 192.168.1.2 or something in that line.

(kde, cli and another option is presented in bottom of thread)

Right-click the network-manager applet on the top panel and choose "connection information" to find it out.

On the computer you want to access the files from, go to "Places -> Connect to Server".

You'll get greeted by this window.

Service type should be "SSH""

Server should be the "ip" adress of the pc where the info is on.

Port, enter "22″

Pick the folder you wish to share (could take some time to connect depending on the size of the folder).

The user name of the pc you are connected to

The bookmark will be the name of the folder in nautilus

After that you'll get a windows where you have to enter a password. That would be the password of the pc you are trying to connect to.

And that's it.

You should have read/write permissions.

You can also connect to your Ubuntu pc running openssh from windows using "Putty" or from OSX using "Fugu". It should work the other way around too.

Note: It might be a good ideo to turn of root logins (for security reasons).

In a terminal

sudo gedit /etc/ssh/sshd_config

Change the line "PermitRootLogin yes" to "PermitRootLogin no".

————–

This won't be possible for all people (for instance when you use fluxbox), then you could try the things below here or just use "gftp". It has an easy to use UI.

————–

If you are using Kubuntu, you can connect to the ssh server using konqueror.

Just type

fish://user@server/path/to/folder

So in reality it could something like this

fish://rw@localhost/home/rw

This would bring you to the /home of the server.

or

fish://rw@192.168.1.3/

This would bring you to / of the server.

If you are on fluxbox, openbox, … nautilus won't be able to handle ssh (or smb). You could still use konqueror but you most likely won't like that.

Then you could use the cli client of you choice and do

ssh user@server

For me this would be:

ssh rw@192.168.1.3

And you would be able to browse the server using the terminal.

Some basic terminal commands are given here.

However, you could use sshfs to mount the the ssh share as a filesystem.

There are instructions to get it working on the official website, but ubuntu.wordpress.com has a nice how-to.

Share files and folders with other computers

Share files and folders with other computers

You can share files and folders with other people on your network through Shared Folders or Nautilus.

Sharing folders via the Shared Folders application

To share folders using the Shared Folders application:

  1. Press ApplicationsAccessoriesTerminal to open a Terminal.

  2. Type shares-admin and press Return to open Shared Folders.

  3. Press the Unlock button and enter your password in the Password for (username): field.

  4. Press the Authenticate button.

  5. You may receive a message which says Sharing services are not installed. If this happens, ensure that the two checkboxes in the message box are checked and press Install services. Sharing service support will then be downloaded and installed; this may take a while.

  6. Select the Shared Folders tab and press Add.

  7. Select the location of the folder you wish to share by changing the Path option.

  8. Choose Windows networks (SMB) from the Share through option.

  9. Enter a name and comment for the shared folder.

  10. If you would like people accessing the shared folder to be able to add, change and remove files in the folder, uncheck Read only. If you leave Read only checked, people will only be able to view files in the folder.

  11. Press OK to make the shared folder available. Other people on the same network (LAN) as you should now be able to access the folder.

See the Shared Folders Administration Tool manual for more information on managing network shares.

Sharing folders via Nautilus

To share folders using Nautilus:

  1. Press PlacesComputer to open a File Browser window.

  2. Right click the folder you wish to share and select Sharing Options on the popup menu.

  3. Select Share this folder from the popup menu. You may change the Share name field if you want to use a different share name.

  4. You may receive a message which says Sharing services are not installed. If this happens, ensure that the two checkboxes in the message box are checked and press Install services. Sharing service support will then be downloaded and installed; this may take a while.

  5. Select Allow other people to write in this folder if you wish to allow others to add, change, and remove files in this folder. If you leave this box unchecked, other people will only be able to view files in this folder. You may also fill in the Comment field.

  6. Select Guest access (for people without a user account) if you wish to allow guest users to access your files.

  7. Press Create share to make the shared folder available.

  8. You may receive a message stating that Nautilus needs to add some permissions to the folder in order to share it. If this happens, press Add the permissions automatically.

  9. Other people on the same network (LAN) as you should now be able to access the folder.

[Note]

You may receive a message which says You do not have permission to create a usershare. If this happens, contact your system administrator or configure the Folder sharing service (samba).

See the Shared Folders Administration Tool manual for more information on managing network shares.

Accessing shared folders via Windows

If you would like to access a shared folder hosted on an Ubuntu computer by using computers running Windows, you may have to perform some additional steps:

  1. Press ApplicationsAccessoriesTerminal to open a Terminal.

  2. Type sudo smbpasswd -a username, replacing "username" with your own username. Press Return to run the command.

    [Note]

    You can find out what your username is by typing whoami into the Terminal and then pressing Return.

  3. Enter your password when prompted with "[sudo] password for username:" and press Return again.

  4. When prompted with "New SMB password:", enter the password that you would like to use to access the shared folder and then press Return. You can leave the password blank, which will allow anyone to access the shared folder.

  5. When prompted with "Retype new SMB password:", enter the password that you just entered and then press Return.

  6. You should now be able to connect to the shared folders on the Ubuntu computer.

Problems connecting to shared folders in Windows

If you are unable to connect to a shared folder using Windows, try using the IP address of the Ubuntu computer rather than its host name to access the share:

  1. Press SystemAdministrationNetwork Tools and select the Devices tab.

  2. Select the name of your network connection from the Network device option list (for example, "eth0"). If you have several network connections, you may have to try this several times.

  3. Make a note of the number in the IP address column. It should consist of four numbers separated by dots (for example, "192.168.2.10")

  4. On the Windows computer, select StartRun and type \\ipaddress in the text box, replacing "ipaddress" with the IP address of the Ubuntu computer

  5. Press OK to connect to the shared folder.

If you are still unable to access the shared folder, check that the folder sharing service is running on the Ubuntu computer:

  1. Press SystemAdministrationServices

  2. Find the Folder sharing service (samba) and ensure that the checkbox next to it is checked. If it is not checked, press Unlock and enter your administrative password. Press Authenticate, then enable the Folder sharing service.

  3. Press Close

More information can be found on the Ubuntu community help pages.

Share folders between two Ubuntu computers on the same LAN with NFS

» Share folders between two Ubuntu computers on the same LAN with NFS // Clara Raubertas // Freelance Web Design & Web Development // Cambridge & Boston, Massachusetts

While most things about Ubuntu work pretty much the way you want/expect the first time, one exception is sharing folders between two computers on the same LAN ("Local Area Network" — in this case, multiple computers in the same house sharing an internet connection via a router). Surprisingly, it's easier/more intuitive to do this between an Ubuntu computer and a Windows computer! I wish Ubuntu would make a more intuitive, graphical way for non-technical users to do this — though I certainly have fun tinkering with these things and learning more about networking (or what-have-you) as I go.

Through some command-line magic, I've gotten my laptop to be able to access the music folder on my desktop — right now I'm playing music on my laptop that's actually stored on my desktop's much bigger hard drive. Sweet! How did I manage this?

Say you have two computers, both running Linux (in this case they're both running Ubuntu and I can't vouch that this will work on any other distro, but I suspect it would) — the server, which has the folder you want to share on its physical media, and the client, which will connect to the server and access its data.

On the client:
1. In a Terminal window, run

sudo apt-get install nfs-common

— this installs the software you'll need.

2. Run

ifconfig

to find your IP on the local network; it should look something like

inet addr:192.168.1.101

(If you see more than one instance of "inet addr" in the output of ifconfig, choose the address that doesn't begin with 127.)

On the server:

3. In a Terminal window, run

sudo apt-get install nfs-kernel-server

4. Edit the

/etc/hosts

file and add a line that looks like this:

neuron 192.168.1.101

where "neuron" is replaced with the hostname or a nickname for your client (in this case, "neuron" is the name of my laptop) and "192.168.1.101″ is replaced with the IP you found in step 2.

5. Test this — in a Terminal, run

ping -c 1 neuron

(or whatever name you used) and see if you get a response. If you get a response like "unknown host", something is wrong — re-check your work from the previous steps (and check that the two computers are really on the same network!). If you get a response like "… 64 bytes from neuron… 1 packets transmitted, 1 received … " then everything is hunky-dory so far and you are ready to move on!

6. Edit the

/etc/hosts.allow

file and add a line that looks like this:

ALL: 192.168.1.101

(again, use the IP that you found in Step 2).

7. Edit the

/etc/exports

file and add a line that looks like this:

/home/music 192.168.1.101(rw,sync,subtree_check,no_root_squash)

where again 192… is replaced with the IP from step 2, and "/home/music" is replaced with the full path to the folder you want to share. Note that for some reason it is important that the parenthesized arguments don't have a space between them.

8. Run

sudo /etc/init.d/nfs-kernel-server restart

9. Run

ifconfig

and get the IP of your server, the same way that you found it for the client.

Back on the client!

10. Edit

/etc/hosts

and add a line like

192.168.1.103 boffin

where "192.168.1.103″ is replaced with the IP of your server (from step 9) and "boffin" is replaced with the hostname/nickname of your server ("boffin" is the name of my desktop).

11.

ping -c 1 boffin

to check that this worked, just like in Step 5.

12. Make a mountpoint for your shared directory — in my case, I used

mkdir /media/boffin-music

13. Mount the shared directory at the mountpoint, like this:

sudo mount -t nfs boffin:/home/music /media/boffin-music

replacing "boffin" with your server's name, "/home/music" with the location on the server of your shared folder, and "/media/boffin-music" with the mountpoint you created in step 12.

14. Now you should be able to browse to the mountpoint and see your shared files, and open them, and use them. Awesome!

Zen Cart - an open source online store management system

Zen Cart - Wikipedia, the free encyclopedia

Zen Cart is an open source online store management system. It is PHP-based, using a MySQL database and HTML components. Support is provided for several languages and currencies, and it is freely available under the GNU General Public License.

Zen Cart branched from osCommerce as a separate project. Beyond some aesthetic changes, the major differences between the two systems come from Zen Cart's architectural changes (e.g. a template system) and additional included features in the core. Among the modules already included are a Gift Certificate/Voucher module which allows to create, send and manage the digital coupons. A module to sell downloads (pdf or other media files) is included as well.

Zen Cart's default installation provides everything needed to maintain a shopping cart web site, however no warranty is given that the software fulfills its purpose. Products, pricing, shipping, newsletters, sales etc. are managed by the store owner through the administration area. The shopping cart is set up to receive payments from major credit cards and several payment gateway services are also provided.

The following is a list of some of the key features of Zen Cart as stated on their website:

  • multiple language support
  • multiple customer modes
  • unlimited category depth
  • multiple sales and discounts
  • multiple display modes
  • XHTML 1.0 compliant template system
  • extra pages
  • multiple ad banner controller
  • multiple shipping options
  • multiple payment options
  • newsletter manager
  • discount coupons
  • gift certificates
  • featured products
  • quantity discounts
  • phpBB integration through external module

Although Zencart improved the shop management and administration with the template system, still it suffers from the fact that editing core files for customizing is often required (no real modular structure). Therefore, in case of heavy customizing, the software is cumbersome to maintain and update. In a later branch of osCommerce, Batavi, this is solved by following an object oriented approach, and strict separation of the design, code and database layers.

See also

External links

List of Open Source eCommerce Software

List of Open Source eCommerce Software - Wikipedia, the free encyclopedia

SSH加密通道配置

SSH加密通道配置-月光博客

  安全外壳协议(Secure Shell Protocol / SSH)是一种在不安全网络上提供安全远程登录及其它安全网络服务的协议。最初是UNIX系统上的一个程序,后来又迅速扩展到其他操作平台。

  常用的SSH工具有开源软件PuTTY,支持SSH远程登录的主机可以实现socks5代理服务器的功能,不过在PuTTY中没有配置文件,需要手动设置才能实现,且无法保存,而PuTTY完整版自带的pLink可以实现命令行方式调用PuTTY实现SSH的加密通道。

  具体的方法是,下载这个文件后解压,pLink的调用参数是:plink -C -v -N -D 本地端口 远程用户@IP或域名:远程希望打开的端口。例如,远程IP为: 111.111.111.111 用户名为abc,本地打开135端口,远程打开22端口,ssh端口为123的,plink -N -D 127.0.0.1:135 abc@111.111.111.111:22。运行完成后,在Firefox中设置SOCK5为本地IP和端口即可。如果觉得pLink还麻烦,使用MyEntunnel(My Encrypted Tunnel)可以图形化实现这个功能。

  配置好SSH之后,还需要配置Firefox浏览器,首先要在Firefox设置SOCKS远程域名解析,主要是为了防止DNS污染,具体设置方法是,在Firefox地址栏中,输入 about:config ,按确认,修改里面的一项数值,改成 network.proxy.socks_remote_dns=true 就可以了。

  然后,打开FireFox浏览器,选择菜单栏的“工具/选项...”。选择“高级/网络”,点设置,就出现下面的界面,就可以进行代理服务器的设置了,选中“手动配置代理”,然后在SOCKS主机上,填写代理服务器的地址127.0.0.1,端口1080,这时Firefox就配置结束。

Featured Post

Windows和Ubuntu双系统完全独立的安装方法

http://www.ubuntuhome.com/windows-and-ubuntu-install.html  | Ubuntu Home Posted by Snow on 2012/06/25 安装Windows和Ubuntu双系统时,很多人喜欢先安装windows,然...