{"id":35882,"date":"2019-05-16T13:23:11","date_gmt":"2019-05-16T20:23:11","guid":{"rendered":"https:\/\/virtual-dba.com\/?p=35882"},"modified":"2023-08-11T08:00:25","modified_gmt":"2023-08-11T15:00:25","slug":"installing-postgresql-ubuntu-virtualbox","status":"publish","type":"post","link":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/","title":{"rendered":"Installing PostgreSQL on Ubuntu VirtualBox"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">PostgreSQL on Ubuntu VirtualBox<\/h2>\n\n\n\n<p>When you first start diving into a new database\nit&#8217;s always difficult to know what environment parameters and resources to use to just get started. I will walk you through setting up VirtualBox, Ubuntu, and <a href=\"https:\/\/virtual-dba.com\/platforms\/postgresql\/\">PostgreSQL<\/a> to get you started.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Downloads<strong><\/strong><\/h3>\n\n\n\n<p>First you will want to download VirtualBox:<br><a href=\"https:\/\/www.virtualbox.org\/wiki\/Downloads\" target=\"_blank\" rel=\"noreferrer noopener\" aria-label=\" (opens in a new tab)\">https:\/\/www.virtualbox.org\/wiki\/Downloads<\/a><\/p>\n\n\n\n<p>Second is the ISO file for Ubuntu 18.04 (or whatever version you want) make sure it is 64bit: <a href=\"https:\/\/www.ubuntu.com\/download\/server\" target=\"_blank\" rel=\"noreferrer noopener\" aria-label=\" (opens in a new tab)\">https:\/\/www.ubuntu.com\/download\/server<\/a><\/p>\n\n\n\n<p>Third is Putty an SSH utility that makes accessing your server much easier:<br><a href=\"https:\/\/www.chiark.greenend.org.uk\/~sgtatham\/putty\/latest.html\" target=\"_blank\" rel=\"noreferrer noopener\" aria-label=\" (opens in a new tab)\">https:\/\/www.chiark.greenend.org.uk\/~sgtatham\/putty\/latest.html<\/a><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Configuring VirtualBox<\/h3>\n\n\n\n<p>The install for VirtualBox is pretty simple, a bunch of next until it\u2019s installed. Once you have it install run the exe and you&#8217;ll come to this window, click the new button in the top left corner.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"633\" height=\"298\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/new_virtualbox_window_1.jpg\" alt=\"new virtualbox window\" class=\"wp-image-35909\"\/><\/figure>\n\n\n\n<p>On the next window you will want to enter the name of the instance, whatever you like. Then select Linux from the type dropdown and Ubuntu 64-bit from the Version dropdown, click Next.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"537\" height=\"483\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/name_and_operating_system_2.jpg\" alt=\"name and operating system\" class=\"wp-image-35906\"\/><\/figure>\n\n\n\n<p>Allocate memory, you don&#8217;t need much if you&#8217;re working with sample data. 1024 is sufficient but I usually go with 4GB just to have room to work. This would also depend on the current memory you have on your system, don&#8217;t use so much that you tax your host operating system, click Next.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"534\" height=\"480\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/memory_size_3.jpg\" alt=\"memory size\" class=\"wp-image-35905\"\/><\/figure>\n\n\n\n<p>Create a new virtual hard disk.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"538\" height=\"479\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/new_virtual_hard_disk_4.jpg\" alt=\"new virtual hard disk\" class=\"wp-image-35908\"\/><\/figure>\n\n\n\n<p>Select the default VDI.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"629\" height=\"518\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/default_VDI_5.jpg\" alt=\"default VDI\" class=\"wp-image-35894\"\/><\/figure>\n\n\n\n<p> Select dynamically allocated. This makes sure that the full disk space won&#8217;t be used until you actually use it in your virtual machine. If you assign 8GB in your next step then that 8GB won\u2019t be reserved, it will be used as needed.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"626\" height=\"518\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/dynamically_allocated_6.jpg\" alt=\"dynamically allocated hard disk file\" class=\"wp-image-35895\"\/><\/figure>\n\n\n\n<p>Select the amount of space you&#8217;ll need. If you&#8217;re importing large amounts of data you will need more disk space, if you&#8217;re just testing then you probably won\u2019t need much, click create.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"626\" height=\"519\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/file_location_and_size_7.jpg\" alt=\"file location and size\" class=\"wp-image-35897\"\/><\/figure>\n\n\n\n<p>You should now be back to the main window for VirtualBox. Next we need to mount the Ubuntu ISO disc so it&#8217;s ready for installation when we start our virtual machine. Click settings at the top.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"738\" height=\"499\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/main_window_settings_8.jpg\" alt=\"main window settings\" class=\"wp-image-35904\"\/><\/figure>\n\n\n\n<p>Here you can remove the empty disk and click remove.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"711\" height=\"501\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/remove_empty_disk_9.jpg\" alt=\"remove empty disk\" class=\"wp-image-35917\"\/><\/figure>\n\n\n\n<p>Click Controller: IDE and then click the Add Optical Drive Icon.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"709\" height=\"503\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/controllerIDE_add_optical_drive_10.jpg\" alt=\"controller:IDE add optical drive\" class=\"wp-image-35893\"\/><\/figure>\n\n\n\n<p>Click Choose Disk.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"333\" height=\"197\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/choose_disk_11.jpg\" alt=\"choose disk\" class=\"wp-image-35890\"\/><\/figure>\n\n\n\n<p>Browse to where you saved the Ubuntu file you downloaded earlier in the Downloads portion of this guide. The name should be similar to the one below, ending in iso and click Open and then click Ok. <\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"510\" height=\"39\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/browse_ubuntu_file_12.jpg\" alt=\"browse ubuntu file\" class=\"wp-image-35889\"\/><\/figure>\n\n\n\n<p> You can now click Start to boot up your virtual machine. <\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"839\" height=\"595\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/start_virtual_machine_13.jpg\" alt=\"start virtual machine\" class=\"wp-image-35919\"\/><\/figure>\n\n\n\n<p>Select the language you want to use, press enter.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"810\" height=\"695\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/select_language_14.jpg\" alt=\"select language\" class=\"wp-image-35918\"\/><\/figure>\n\n\n\n<p>If you are using a different keyboard layout than the standard select it here, otherwise just hit enter again.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"818\" height=\"696\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/identify_keyboard_15.jpg\" alt=\"identify keyboard\" class=\"wp-image-35900\"\/><\/figure>\n\n\n\n<p>Press enter again.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"808\" height=\"693\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/Install_ubuntu_15.jpg\" alt=\"Install ubuntu\" class=\"wp-image-35902\"\/><\/figure>\n\n\n\n<p>You can press enter to go through this screen however your IP may differ show on the adapter. If you&#8217;re on wireless like I am you may have to take an additional step in order to connect to your server. I will show this in a later step.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"809\" height=\"693\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/network_connections_16.jpg\" alt=\"network connections\" class=\"wp-image-35907\"\/><\/figure>\n\n\n\n<p>If you have a proxy you need to use, enter it here and press enter.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"813\" height=\"692\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/configure_proxy_17.jpg\" alt=\"configure proxy\" class=\"wp-image-35892\"\/><\/figure>\n\n\n\n<p> Use the default mirror and press enter.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"812\" height=\"692\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/configure_archive_mirror_17.jpg\" alt=\"configure archive mirror\" class=\"wp-image-35891\"\/><\/figure>\n\n\n\n<p>Select use an entire disk and press return.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"810\" height=\"694\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/filesystem_setup_18.jpg\" alt=\"filesystem setup\" class=\"wp-image-35898\"\/><\/figure>\n\n\n\n<p>Select the disk, it should be the same amount you allocated earlier in the VirtualBox settings.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"814\" height=\"694\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/filesystem_setup_size_19.jpg\" alt=\"filesystem setup size\" class=\"wp-image-35899\"\/><\/figure>\n\n\n\n<p>Partition 1 and 2 should equal the total disk space available, 8GB in this case. Select Done and press enter.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"814\" height=\"693\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/partitions_disk_space_20.jpg\" alt=\"partitions disk space\" class=\"wp-image-35910\"\/><\/figure>\n\n\n\n<p>Fill in the desire information how you want to and also choose a password, remember this password you will need it to login to your server, select Done and press enter.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"816\" height=\"693\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/profile_setup_21.jpg\" alt=\"profile setup\" class=\"wp-image-35912\"\/><\/figure>\n\n\n\n<p>Select postgresql10 and press space bar to mark it, then scroll down to done and press enter.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"813\" height=\"692\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/installation_complete_22.jpg\" alt=\"installation complete\" class=\"wp-image-35903\"\/><\/figure>\n\n\n\n<p>Select Reboot Now and press enter.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"815\" height=\"693\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/reboot_now_23.jpg\" alt=\"reboot now\" class=\"wp-image-35916\"\/><\/figure>\n\n\n\n<p>If you see the message about failing to unmount a disk, go to the top of your VM and click Devices, then Optical Drives. Click the .iso so there is a checkmark to the left of it, then click &#8216;Remove disk from virtual drive&#8217;. Then click back into your VM and press Enter. You should see the server load and a username prompt.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"847\" height=\"697\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/failing_to_unmount_disk_24.jpg\" alt=\"failing to unmount disk\" class=\"wp-image-35896\"\/><\/figure>\n\n\n\n<p>At this point we&#8217;re going to switch to Putty to finish\ninstalling PostgreSQL and also test that we can get a connection to the server from your host machine.<\/p>\n\n\n\n<p>Once logged in with your username and password you assigned\nearlier, use this command: <\/p>\n\n\n\n<p><code>Ifconfig<\/code><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"812\" height=\"693\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/putty_command_25.jpg\" alt=\"putty command\" class=\"wp-image-35913\"\/><\/figure>\n\n\n\n<p>Note the &#8216;inet&#8217; address, 192.168.1.18 in this case.<\/p>\n\n\n\n<p>Open Putty and enter the IP address, leave the port as 22, you can save the information by putting a name for the connection in the &#8216;Saved Sessions&#8217; box and clicking Save on the right. Then click Open. You should connect and receive a prompt to login. If you receive a window before asking if you want to connect to an insecure server, click Yes.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"605\" height=\"536\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/putty_IP_address_26.jpg\" alt=\"putty IP address\" class=\"wp-image-35915\"\/><\/figure>\n\n\n\n<p>If you&#8217;re unable to connect to the server, you may have to bridge your connection in VirtualBox.<\/p>\n\n\n\n<p>Go back to VirtualBox Manager and click Settings at the top for your VM, click Network on the left and make sure it looks like the example below. Click Ok, then reset your server by Right Clicking it in the window and clicking Reset. Then try your Putty connection again and it should work.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"713\" height=\"504\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/bridge_connection_27.jpg\" alt=\"bridge connection\" class=\"wp-image-35888\"\/><\/figure>\n\n\n\n<p>Once logged into your server inside Putty run the command: <code>sudo apt-get update<\/code><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"836\" height=\"525\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/putty_command_sudo_28.jpg\" alt=\"putty command sudo\" class=\"wp-image-35914\"\/><\/figure>\n\n\n\n<p>Next, we&#8217;ll be updating the repositories for PostgreSQL before we install. Run the three commands below, your results should be similar to the example shown.<\/p>\n\n\n\n<code><ol class=\"wp-block-list\"><li>wget -q https:\/\/www.postgresql.org\/wp-content\/uploads\/keys\/ACCC4CF8.asc -O- | sudo apt-key add -<\/li><li>echo \"deb http:\/\/apt.postgresql.org\/pub\/repos\/apt\/ bionic-pgdg main\"      | sudo tee \/etc\/apt\/sources.list.d\/postgresql.list<\/li><li>sudo apt      update<\/li><\/ol><\/code>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"836\" height=\"506\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/updating_repositories_30.jpg\" alt=\"updating repositories\" class=\"wp-image-35920\"\/><\/figure>\n\n\n\n<p>We can now install PostgreSQL:<\/p>\n\n\n\n<code><ol class=\"wp-block-list\"><li>sudo apt install -y postgresql-10<\/li><\/ol><\/code>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"834\" height=\"504\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/install_postgresql_31.jpg\" alt=\"install postgresql\" class=\"wp-image-35901\"\/><\/figure>\n\n\n\n<p>In order to start PostgreSQL you have to be using the\npostgres user. You can&#8217;t use the user you created before. Switch to the\npostgres user:<\/p>\n\n\n\n<p><code>sudo su postgres<\/code><\/p>\n\n\n\n<p>You can then start PostgreSQL console:<\/p>\n\n\n\n<p><code>Psql<\/code><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"835\" height=\"504\" src=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/postgres_user_32.jpg\" alt=\"postgres user\" class=\"wp-image-35911\"\/><\/figure>\n\n\n\n<p>You&#8217;re now all set to start using PostgreSQL. I recommend\ninstalling PGAdmin and using the same credentials that you did for Putty to connect to your server. This should give you everything you need to start inserting data and testing configurations for your environment.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>PostgreSQL on Ubuntu VirtualBox When you first start diving into a new database it&#8217;s always difficult to know what environment parameters and resources to use to just get started. I will walk you through setting up VirtualBox, Ubuntu, and PostgreSQL to get you started. Downloads First you will want to download VirtualBox:https:\/\/www.virtualbox.org\/wiki\/Downloads Second is the [&hellip;]<\/p>\n","protected":false},"author":3,"featured_media":35885,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_et_pb_use_builder":"off","_et_pb_old_content":"","_et_gb_content_width":"","content-type":"","footnotes":""},"categories":[4166,2163],"tags":[3961,3962],"class_list":["post-35882","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blog","category-postgresql","tag-postgresql-installation","tag-ubuntu"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.1 (Yoast SEO v27.1.1) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Installing PostgreSQL on Ubuntu VirtualBox - Virtual-DBA Remote DBA Services &amp; Support - Certified Database Experts<\/title>\n<meta name=\"description\" content=\"Install PostgreSQL on Ubuntu VirtualBox for data testing. Setup guide for Ubuntu, VirtualBox, and PostgreSQL. Get started today!\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Installing PostgreSQL on Ubuntu VirtualBox\" \/>\n<meta property=\"og:description\" content=\"Install PostgreSQL on Ubuntu VirtualBox for data testing. Setup guide for Ubuntu, VirtualBox, and PostgreSQL. Get started today!\" \/>\n<meta property=\"og:url\" content=\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/\" \/>\n<meta property=\"og:site_name\" content=\"Virtual-DBA Remote DBA Services &amp; Support - Certified Database Experts\" \/>\n<meta property=\"article:published_time\" content=\"2019-05-16T20:23:11+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-08-11T15:00:25+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"557\" \/>\n\t<meta property=\"og:image:height\" content=\"291\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"XTIVIA\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@virtual_dba\" \/>\n<meta name=\"twitter:site\" content=\"@virtual_dba\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"XTIVIA\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"11 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/\"},\"author\":{\"name\":\"XTIVIA\",\"@id\":\"https:\/\/virtual-dba.com\/#\/schema\/person\/2d86f74bed0c3f1b49100f7fdf7d78d1\"},\"headline\":\"Installing PostgreSQL on Ubuntu VirtualBox\",\"datePublished\":\"2019-05-16T20:23:11+00:00\",\"dateModified\":\"2023-08-11T15:00:25+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/\"},\"wordCount\":1006,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/virtual-dba.com\/#organization\"},\"image\":{\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg\",\"keywords\":[\"PostgreSQL Installation\",\"Ubuntu\"],\"articleSection\":[\"Blog\",\"PostgreSQL\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/\",\"url\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/\",\"name\":\"Installing PostgreSQL on Ubuntu VirtualBox - Virtual-DBA Remote DBA Services &amp; Support - Certified Database Experts\",\"isPartOf\":{\"@id\":\"https:\/\/virtual-dba.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg\",\"datePublished\":\"2019-05-16T20:23:11+00:00\",\"dateModified\":\"2023-08-11T15:00:25+00:00\",\"description\":\"Install PostgreSQL on Ubuntu VirtualBox for data testing. Setup guide for Ubuntu, VirtualBox, and PostgreSQL. Get started today!\",\"breadcrumb\":{\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#primaryimage\",\"url\":\"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg\",\"contentUrl\":\"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg\",\"width\":557,\"height\":291},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/virtual-dba.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Installing PostgreSQL on Ubuntu VirtualBox\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/virtual-dba.com\/#website\",\"url\":\"https:\/\/virtual-dba.com\/\",\"name\":\"Virtual-DBA Remote DBA Services &amp; Support - Certified Database Experts\",\"description\":\"Remote Database Administration\",\"publisher\":{\"@id\":\"https:\/\/virtual-dba.com\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/virtual-dba.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/virtual-dba.com\/#organization\",\"name\":\"Virtual-DBA: Remote DBA | Remote Database Administration\",\"alternateName\":\"Virtual-DBA powered by XTIVIA\",\"url\":\"https:\/\/virtual-dba.com\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/virtual-dba.com\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/virtual-dba.com\/wp-content\/uploads\/V-DBA-Database-Services-and-Support-Featured-Logo.jpg\",\"contentUrl\":\"https:\/\/virtual-dba.com\/wp-content\/uploads\/V-DBA-Database-Services-and-Support-Featured-Logo.jpg\",\"width\":557,\"height\":291,\"caption\":\"Virtual-DBA: Remote DBA | Remote Database Administration\"},\"image\":{\"@id\":\"https:\/\/virtual-dba.com\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/x.com\/virtual_dba\",\"https:\/\/www.linkedin.com\/showcase\/36220649\/\",\"https:\/\/www.youtube.com\/channel\/UCx3AIeUQ2ziTLKZSJDZ-SEg\"],\"description\":\"Eliminate database downtime and spiraling costs with XTIVIA\u2019s Virtual-DBA. In today\u2019s always-on business world, gaps in 24x7 on-call DBA support, neglected maintenance and security, or a stretched team struggling with overwhelming workloads can lead to costly disruptions and threaten business continuity. XTIVIA\u2019s Virtual-DBA provides the immediate, expert database administration you need, exactly when you need it, ensuring optimal performance, ironclad security, and significant cost savings without the burden of expanding your in-house team. The goal of Virtual-DBA is to provide a cost-effective solution for organizations seeking to optimize the security, management, maintenance, availability, and performance of their critical business systems, whether self-managed or cloud-managed (e.g., AWS RDS, Azure SQL Database). We accomplish this through a comprehensive remote DBA service offering designed specifically to meet the Oracle\u00ae, DB2\u00ae, Informix\u00ae, MySQL\u2122, PostgreSQL\u00ae, MongoDB\u00ae, MariaDB, and Microsoft SQL Server\u00ae, CockroachDB, Databricks, AWS, and Azure needs of our clients.\",\"email\":\"info@xtivia.com\",\"telephone\":\"8886853101\",\"legalName\":\"XTIVIA, Inc\",\"foundingDate\":\"1992-05-01\",\"numberOfEmployees\":{\"@type\":\"QuantitativeValue\",\"minValue\":\"201\",\"maxValue\":\"500\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/virtual-dba.com\/#\/schema\/person\/2d86f74bed0c3f1b49100f7fdf7d78d1\",\"name\":\"XTIVIA\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/virtual-dba.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/0d3648a00e319a37cf8d6d19f762acfbbb4fd0320fd8a6d6b1e64f44a2a6f259?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/0d3648a00e319a37cf8d6d19f762acfbbb4fd0320fd8a6d6b1e64f44a2a6f259?s=96&d=mm&r=g\",\"caption\":\"XTIVIA\"},\"url\":\"https:\/\/virtual-dba.com\/author\/xtivia\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Installing PostgreSQL on Ubuntu VirtualBox - Virtual-DBA Remote DBA Services &amp; Support - Certified Database Experts","description":"Install PostgreSQL on Ubuntu VirtualBox for data testing. Setup guide for Ubuntu, VirtualBox, and PostgreSQL. Get started today!","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/","og_locale":"en_US","og_type":"article","og_title":"Installing PostgreSQL on Ubuntu VirtualBox","og_description":"Install PostgreSQL on Ubuntu VirtualBox for data testing. Setup guide for Ubuntu, VirtualBox, and PostgreSQL. Get started today!","og_url":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/","og_site_name":"Virtual-DBA Remote DBA Services &amp; Support - Certified Database Experts","article_published_time":"2019-05-16T20:23:11+00:00","article_modified_time":"2023-08-11T15:00:25+00:00","og_image":[{"width":557,"height":291,"url":"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg","type":"image\/jpeg"}],"author":"XTIVIA","twitter_card":"summary_large_image","twitter_creator":"@virtual_dba","twitter_site":"@virtual_dba","twitter_misc":{"Written by":"XTIVIA","Est. reading time":"11 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#article","isPartOf":{"@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/"},"author":{"name":"XTIVIA","@id":"https:\/\/virtual-dba.com\/#\/schema\/person\/2d86f74bed0c3f1b49100f7fdf7d78d1"},"headline":"Installing PostgreSQL on Ubuntu VirtualBox","datePublished":"2019-05-16T20:23:11+00:00","dateModified":"2023-08-11T15:00:25+00:00","mainEntityOfPage":{"@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/"},"wordCount":1006,"commentCount":0,"publisher":{"@id":"https:\/\/virtual-dba.com\/#organization"},"image":{"@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#primaryimage"},"thumbnailUrl":"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg","keywords":["PostgreSQL Installation","Ubuntu"],"articleSection":["Blog","PostgreSQL"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/","url":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/","name":"Installing PostgreSQL on Ubuntu VirtualBox - Virtual-DBA Remote DBA Services &amp; Support - Certified Database Experts","isPartOf":{"@id":"https:\/\/virtual-dba.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#primaryimage"},"image":{"@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#primaryimage"},"thumbnailUrl":"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg","datePublished":"2019-05-16T20:23:11+00:00","dateModified":"2023-08-11T15:00:25+00:00","description":"Install PostgreSQL on Ubuntu VirtualBox for data testing. Setup guide for Ubuntu, VirtualBox, and PostgreSQL. Get started today!","breadcrumb":{"@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#primaryimage","url":"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg","contentUrl":"https:\/\/virtual-dba.com\/wp-content\/uploads\/Installing-PostgreSQL-on-Ubuntu-VirtualBox.jpg","width":557,"height":291},{"@type":"BreadcrumbList","@id":"https:\/\/virtual-dba.com\/blog\/installing-postgresql-ubuntu-virtualbox\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/virtual-dba.com\/"},{"@type":"ListItem","position":2,"name":"Installing PostgreSQL on Ubuntu VirtualBox"}]},{"@type":"WebSite","@id":"https:\/\/virtual-dba.com\/#website","url":"https:\/\/virtual-dba.com\/","name":"Virtual-DBA Remote DBA Services &amp; Support - Certified Database Experts","description":"Remote Database Administration","publisher":{"@id":"https:\/\/virtual-dba.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/virtual-dba.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/virtual-dba.com\/#organization","name":"Virtual-DBA: Remote DBA | Remote Database Administration","alternateName":"Virtual-DBA powered by XTIVIA","url":"https:\/\/virtual-dba.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/virtual-dba.com\/#\/schema\/logo\/image\/","url":"https:\/\/virtual-dba.com\/wp-content\/uploads\/V-DBA-Database-Services-and-Support-Featured-Logo.jpg","contentUrl":"https:\/\/virtual-dba.com\/wp-content\/uploads\/V-DBA-Database-Services-and-Support-Featured-Logo.jpg","width":557,"height":291,"caption":"Virtual-DBA: Remote DBA | Remote Database Administration"},"image":{"@id":"https:\/\/virtual-dba.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/x.com\/virtual_dba","https:\/\/www.linkedin.com\/showcase\/36220649\/","https:\/\/www.youtube.com\/channel\/UCx3AIeUQ2ziTLKZSJDZ-SEg"],"description":"Eliminate database downtime and spiraling costs with XTIVIA\u2019s Virtual-DBA. In today\u2019s always-on business world, gaps in 24x7 on-call DBA support, neglected maintenance and security, or a stretched team struggling with overwhelming workloads can lead to costly disruptions and threaten business continuity. XTIVIA\u2019s Virtual-DBA provides the immediate, expert database administration you need, exactly when you need it, ensuring optimal performance, ironclad security, and significant cost savings without the burden of expanding your in-house team. The goal of Virtual-DBA is to provide a cost-effective solution for organizations seeking to optimize the security, management, maintenance, availability, and performance of their critical business systems, whether self-managed or cloud-managed (e.g., AWS RDS, Azure SQL Database). We accomplish this through a comprehensive remote DBA service offering designed specifically to meet the Oracle\u00ae, DB2\u00ae, Informix\u00ae, MySQL\u2122, PostgreSQL\u00ae, MongoDB\u00ae, MariaDB, and Microsoft SQL Server\u00ae, CockroachDB, Databricks, AWS, and Azure needs of our clients.","email":"info@xtivia.com","telephone":"8886853101","legalName":"XTIVIA, Inc","foundingDate":"1992-05-01","numberOfEmployees":{"@type":"QuantitativeValue","minValue":"201","maxValue":"500"}},{"@type":"Person","@id":"https:\/\/virtual-dba.com\/#\/schema\/person\/2d86f74bed0c3f1b49100f7fdf7d78d1","name":"XTIVIA","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/virtual-dba.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/0d3648a00e319a37cf8d6d19f762acfbbb4fd0320fd8a6d6b1e64f44a2a6f259?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/0d3648a00e319a37cf8d6d19f762acfbbb4fd0320fd8a6d6b1e64f44a2a6f259?s=96&d=mm&r=g","caption":"XTIVIA"},"url":"https:\/\/virtual-dba.com\/author\/xtivia\/"}]}},"_links":{"self":[{"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/posts\/35882","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/comments?post=35882"}],"version-history":[{"count":0,"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/posts\/35882\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/media\/35885"}],"wp:attachment":[{"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/media?parent=35882"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/categories?post=35882"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/virtual-dba.com\/wp-json\/wp\/v2\/tags?post=35882"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}