What's new

Sariling proxy/ssh/openvpn/shadowsocks server tutorial

tekninja

Honorary Poster
Joined
Apr 6, 2017
Posts
287
Reaction
885
Points
218
WARNING: This is an Advanced Tutorial. Pabababawin ko as much as possible pero kung dumudugo na talaga ilong mo, andyan si bestfriend google, magpatulong ka. If positive ang naging response ng mga kaPHC natin possible na gawan ko ng post ang ilang definitions na hindi alam lalo na ng mga newbies. Kung malakas ang loob mong matuto, bilib ako sayo, keep on reading.

UPDATE: My tutorial primarily used VULTR servers (mas madali kasi dun maka free trial) na sa ngayun ay minsan may problem sa accuracy ng bandwidth usage. Kung maencounter mo ito, contact nyo ang support team nila. If it persists, go with DigitalOcean, though need mo ng Credit Card para maka-create ng VPS.


Advanced Tutorials for kaPHC Series
Paano Magkaroon ng Sariling Proxy/SSH/OpenVPN/Shadowsocks Server?

Part 1 – Kailangan mo ng VPS (Virtual Private Server)

Q&A

1. Ano ang VPS o Virtual Private Server?

a. Himayin natin, “SERVER”. So computer ito na ang purpose ay ang mag-provide ng Services. Sa ilan na familiar sa tunneling (yang tinatawag mo na freenet/häçknet/promonet), ang example ng services ay SSH, OpenVPN, Shadowsocks, Proxy, etc. Sa iba naman na may idea sa Web Developer, ang example ng services ay LAMP, MySQL, etc. at sa mga Network Admin familiar sa inyo ang services na DNS, DHCP, etc. Ang mga services na ito ay naipo-provide ng server gamit ang tinatawag na “ports”.

b. Ito naman, “PRIVATE”. Kasi hindi public, haha! Ikaw lang ang may exclusive access sa server na ito kaya “PRIVATE SERVER”.

c. Last, “VIRTUAL”. Sa mga IT dyan may hint na kayo. Sa hindi IT paki google nalang ang “server virtualization” para indepth. Para sa mababaw na paliwanag, sa isang supercomputer (or any computer) pwede kang gumawa ng virtual computer sa loob nito. Example: So sa halip na bumili ka ng 10 physical computers, pwedeng bumili ka lang ng 1 high specs na physical computer at mag-create ka ng 10 virtual computers programmatically. Whey! Di nyo gets? Bahala kayo, haha!

d. Hindi mo kaylangan bumili ng bagong computer set para ikaw mismo mag-virtuallize, may mga nagooffer nito online. Read futher for details.


2. Ano ang advantages kapag meron kang sariling VPS?

a. Learning and Experience. So ano ngayun kung may panload ka o may pambayad ka monthly para sa broadband mo, bakit ako wala ba? Point is, nothing beats the power of knowledge. Kung enthusiast ka man o IT student, plus-plus na ito na marunong ka mag admin ng VPS.

b. Savings (Allot of savings…). Sure, maintaining your own VPS involves around $5.00 (Php250) a month.

Pero sira ka ba? Globe charges Php299 for 1.5GB a month for postpaid subscribers (like me by the way), and charges Php1,499 for 30GB @ 5mbps for broadband subscribers (like me also).

But the cheapest VPS worth Php250/month has 10gbps (10,000mbps) bandwidth and 1tb (1000 gigabyte) data cap, with your own STATIC IP pa! So the only limit in speed is your own connection papuntang server mo (tabihan mo nalang towers ng telco kung may rush kang download, para maximum LTE+ speed ka, haha!). Kita nyo kung pano tayo kinagatasan ng mga telcos, ang layo ng specs compared sa internet mo sa bahay.

Saka hindi lang naman ikaw gagamit nyan kapag meron kang sariling VPS, pwede sa buong pamilya at mga kamag-anak (savings!), pwede sa barkada (savings!), pwede sa katropa sa PHC (savings!) at pwede rin sa fb friends mo (kasi pasikat ka diba? Haha! Atleast ngayun sa iyo talaga ang isi-share mo at hindi galing sa hit and run.) P.S. Sa mga gigil sa mga nag-hihit-and-run, hindi ako kampi sa kanila, pero mag-email ka rin ng thank you sa hinihingan mo ng accounts kasi server nila yun, hit-and-run ka rin isaka pa, haha! Oh yan balanced na ha.

c. Forever (Technically…). Well, masakit man tanggapin pero lahat ng proxy, openvpn, ssh at shadowsocks config dyan na nagkalat ay hindi poreber. Gumawa ka nalang ng poreber mo. Atleast kapag wala ka nang pambayad sa VPS mo, alam mo nang iiwan ka na nya at hindi ka na masyadong masasaktan. Eh kung meron ka na ulit pambili ng credits ng VPS mo, magbalikan na kayo (Yey!).


3. Saan nakakakuha ng sariling VPS?

NOTE: I have no affiliation with these companies. I don't affiliate links para kumita. This is nothing but a free service para sa taumbayan.

a. Vultr - vultr.com – INFOS: Ang payment options mo dito ay either Credit/Debit Card, Paypal, etc. Kapag Debit Card (ex. Paymaya, etc.) or Paypal gamit mo required ka magpreload ng $5 to $10 or around Php250-500. Kapag Credit Card naman, connection lang ang kaylangan nila then after ka makagamit ng 1 month saka sya magcha-charge. Hindi ito spam ha, gamit ko si VULTR sa work at minsan sa pang-personal. Ang maganda pa dito, per hour ang charges nya, around $0.007 per hour. So, kung after 3 days tinangal mo na yung VPS instance mo, dika macha-charge ng $5.00 kundi kung ilang hours lang nag-exist yung ginawa mong VPS Instance. So far angat sa specs dito compared sa iba.

3a.jpg

b. Digital Ocean - digitalocean.com – INFOS: Same lang payment options dito, maganda lang dito may promo sila na free $10 credit (Promo Code: ACTIVATE10) kapag successfully ka na nakapagregister. Same din na per hour ang charges. Ang difference lang nito ay locations na mapagpipiliin sa pagdedeploy ng VPS.

3b.jpg

c. WALA AKONG PAMBILI - Hahaha! Ako wala narin yata... Haha! Eto kababayan, pwede tayo magpractice ng server skills kahit walang pambili: https://phcorner.net/t/practice-mode-tayo-with-virtual-machines-part-1.379757/ Para master ka na muna, pag may pambili na edi sulit!

TRIVIA: Alam mo ba na ang mga websites na namimigay ng free ssh at shadowsocks account ay actually accounts created from DigitalOcean/Vultr/Amazon/Linode/etc na VPS.

4. Paano Gumawa ng VPS?

a. Gumawa ka ng account mo either sa VULTR o Digital Ocean. But for this post papakita ko pano gumawa ng simpleng VPS sa VULTR na may CentOS na Operating System.

b. Kung decided ka na talaga, prep na natin ang kaylangan.

i. Need mo ng Debit Card (ex. Paymaya), Credit Card (hiram ka nalang sa friend), or kung freelancer ka malamang may Paypal ka na, na pwede mong ipang-gawa ng account mo.

ii. Need din natin ng SSH Client. Para ito sa remote management. Download ka ng Bitvise, Putty or MobaXterm for Windows PC (if Linux gamit mo, you know the drill). Kung alin dyan kilala mo sa software kahit yung hindi ko nailagay, yun na gamitin mo basta ssh client. Pwede din sa Android, usually yung JuiceSSH gamit ko. Pero sa demo na ito, MobaXterm gagamitin ko. Download nyo dito - You do not have permission to view the full content of this post. Log in or register now.

iii. Need natin ng internet connection. Hoy kuripot, mag gosurf15 ka muna para sa project lang na ito para walang aberya. After mo makagawa ng sarili mong VPS saka ka mag bagong buhay. Haha!

c. Congrats muna kung nakagawa ka na ng first VPS mo! Login ka na. Makikita mo na wala kapang VPS instances. Sa Server Page may button sa left side na Circle at may Plus sa gitna. Yan ang iki-click natin to add server.

4c.jpg

d. Pili ka ng location kung saan mo gusto magdeploy ng server. TIPS: Sa mga nasubukan ko kapag Proxy at SSH/OVPN combo malinis connection sa Amsterdam, Netherlands at Los Angeles, US (pero around 200-300 ang ping) kasi sa Tokyo at Singapore gumagapang ang speed. Pero kapag Shadowsocks naman kayo sa Singapore ang stable at mababa ang ping. But you can experiment naman depende din yan sa telco mo at sa location mo.

4d.jpg

e. Scroll down lang. Then pili ka ng Server Type. Kung susundan mo tutorial na ito piliin mo ang CentOS 7 x64.

4e.jpg

f. Scroll down ulit. Pili ka ng Server Size. Yung pinakamura ok nay un.

4f.jpg

g. Scroll down again. Sa Additional Features, huwag kalimutan na icheck ang Enable IPv6 at Enable Private Network for future use.

4g.jpg

h. Scroll natin sagad. Bigyan mo ng name ang VPS mo, then click Deploy Now.

4h.jpg

i. Hintayin mo matapos mag install.

4i.jpg

j. Kapag “Running” na ang naka-indicate, click mo yung Elipses Button (tatlong dots) na nasa kanang tabi nung “Running” indicator. May lalabas na menu, piliin mo yung “Server Details” dadalhin ka nito sa server menu.

4j.jpg

k. Sa Server Menu, kapag wala pang values yung CPU Usage ang ibig sabihin ay nagfa-finalize pa ang installation. Kapag meron na kahit 0% ang CPU Usage value click na natin ang “View Console” na naka-indicate or click natin ang View Console Icon mismo.

4k.jpg

l. Kapag “guest login” ang nag-welcome sayo, the server is online. Pwede na sa console na yan magsimula maginstall ng kahit anong gusto mong services ex. SSH, Proxy, OpenVPN, Shadowsocks, etc. Pero I would advice you na wag ka dyan gagawa kasi walang cut and paste feature yan. Mahirap magtype ng lahat ng commands isa isa, hehe. For that gagamit tayo ng MobaXterm.

4l.jpg

m. Close na natin yung nag-pop-up na console at i-open na natin si MobaXterm. Right-Click natin ang “Saved Sessions” then click “New Session”.

WAIT WALA AKO PC! Oh no, wawa naman... Tsk!
Edi sa Android tayo boss... Yey!
https://phcorner.net/t/pwede-yang-android-mo-for-vps-alternative-series.380092/

4m.jpg

n. Click natin (1) SSH Button, (2) Copy natin yung IP Address ng server at ilagay sa “Remote host”, then (3) Click natin User Icon.

4n.jpg

o. Magpa-pop-up ang Username Settings. Click New, then bigyan mo ng name ex. PHCUser, then copy natin account ng VPS natin. Username – root, then Password – yung password ng VPS (click mo lang yung copy button or show button). Then ok twice tayo para makabalik sa Session Settings.

4o.jpg

p. Pagbalik sa Session Settings check lang ang “Specify Username” then piliin lang natin ang ginawa nating user (ex. phcuser). Then OK.

4p.jpg

q. Congrats ulit! You have now the full control of your VPS. Dito ka makakapagsimula mag install ng services na kaylangan mo.

4q.jpg

Ok mga kaPHC end na muna long tutorial ko from here. Ang susunod ko na gagawing tutorial ay introduction sa paggawa ng services tulad ng sarili ninyong Proxy, SSH, OpenVPN, at Shadowsocks.

PART 2
https://phcorner.net/t/sariling-proxy-ssh-openvpn-shadowsocks-server-part-2.375922/

PROXY SERVER Tutorial

https://phcorner.net/t/sarili-mong-proxy-server-tutorial-series.376257/

OPENVPN SERVER Tutorial
https://phcorner.net/t/sarili-mong-openvpn-server-tutorial-series.376338/

SSH TUNNELING SERVER Tutorial
https://phcorner.net/t/sarili-mong-ssh-tunneling-server-tutorial-series.376834/#post-5519976

SHADOWSOCKS SERVER Tutorial
https://phcorner.net/t/sarili-mong-shadowsocks-server-tutorial-series.377223/#post-5528773

BONUS EXTENDED SERIES

TORRENT SERVER Tutorial
Soon!
Give me a few weeks... May Big Project lang at the moment.
Para may idea kayo, and to help narin, i-link ko muna yung isa kong thread:
https://phcorner.net/t/download-tayo-ng-torrent-kahit-blocked-ang-port-hiperdown-style.376897/

INFOS habang hindi pa tapos ang Tutorial Series

Sa mga hindi makapaghintay eto ang mga tuts ng mga banyaga.
Paalala lang kung muuna kayo through these links, baka hindi ko kayo matulungan kapag pumalpak. You will encounter issues with port or firewall problems, patulong nalang kayo kay google.

Oh, ito na para sa mga matatatag talaga ng ******:

Create your own Proxy Server -

You do not have permission to view the full content of this post. Log in or register now.

Create your own ShadowSocks Server -

You do not have permission to view the full content of this post. Log in or register now.

Create your own SSH Server -

*since may ssh na ang server na ginawa nating account, gagwa ka nalang ng users for tunneling
You do not have permission to view the full content of this post. Log in or register now.
*warning: wag mo gagamitin para pang tunneling lang o ipapamigay ang ssh account na “root”

Create your own OpenVPN Server –

You do not have permission to view the full content of this post. Log in or register now.

Sa mga marunong na sa linux, enjoy! :)

I want to hear your response mga kaPHC, dito ko malalaman kung gagawa paga ako ng Part 2 ng tutorial.

 

Attachments

Last edited:
Mherbin

Kung you mean capping sa promo, oo meron kapag PROXY/SSH ka...
Kapag Shadowsocks ka ang magaaply na capping yung capping mismo ng server mo. Sa pinakamura 1000GB ang cap.

4f.jpg
 

Attachments

permon

Credit system yan, bibili ka ng credits tapos ikaw na bahala kung ano kukunin mo... Ang maganda dyan per hour ang charge. Meaning if this month gumawa ka ng VPS tapos 3 days dinilete mo na, 72 hours lang babayaran mo.
 
hypermix24

Sadly wala sa Pinas, if merong nakakaalam pashare. Pero may way tayo dyan. Example, kung may bahay ka na may Internet Subscription at my PC ka na hindi ginagamit, setup ka ng server tapos installan mo kung anong tunneling service gusto mo. Ofcourse medyo mas mabusisi kasi kaylangan mo pa ng DynDNS. Pero kung habol mo ay ping experiment nalang sa locations. Kung very low ping sa isa, delete mo nalang gawa kang bago sa iba.
 

Similar threads

Back
Top