DataStax Cassandra 3.2 Bash Install Script

  • 0

DataStax Cassandra 3.2 Bash Install Script

Get Social!

The below script installs the DataStax distribution of Cassandra 3.2.x and the latest Oracle Java 8 on Debian. Copy and paste the script into a file called install_cassandra.sh and execute it as root.

Change the version 3.2 on line 12 to match the version you’d like to install.

Then connect to the local Cassandra instance run the cqlsh tool.

 


  • 0

Automated Bash MongoDB 3.2 Install Script for Debian/ Ubuntu

Get Social!

mongodb-logoMongoDB is one of the leading noSQL breeds of database that’s been growing in popularity in recent years. The database is available in a ‘community edition’ that’s available for all to use freely.

The database setup and install is mostly straightforward however there are a few steps you have to take to get a MongoDB instance up and running.

The binaries aren’t shipped by the common Linux distributions so you’ll need to add the apt repositories hosted by mongodb.org. After installing the binaries there are a few config options that can be helpful to start with that are not contained in the default MongoDB install.

First off, create a file on your server called install_mongo.sh and copy the content of the script into it found in the below link.

MongoDB 3.2 Bash Install Script

Then make the script executable and run it.

Once the script completes you’ll be able to connect to your MongoDB instance with adminadmin.

What the MongoDB install script does

The following is a brief outline of the steps the script takes:

  1. Add the apt repository from mongodb.org and associated key.
  2. Install the full mongo-org package containing these packages: mongodb-org-server, mongodb-org-mongos, mongodb-org-shell, mongodb-org-tools.
  3.  Add a basic config file that:
    1. Enforces the wiredTiger storage engine.
    2. Enables remote access by listening on ALL interfaces.
    3. Enables replication, even if it’s just a stand alone node.
    4. Enables user authentication.
  4. Initiates the server as a replication cluster.
  5. Adds a user for administration called admin with password admin.

 


  • 0

MongoDB 3.2 Bash Install Script

Get Social!

The below script installs MongoDB 3.2.x on Debian. Copy and paste the script into a file called install_mongo.sh and execute it as root.

Then connect to the local MongoDB instance

 


  • 0

Script To Create A Swapfile On Linux

Category : How-to

Get Social!

This 5 line script will quickly create a 512MB SWAP file that will be automatically mounted on each machine reboot. It assumes you don’t already have a swap file enabled.

The script creates a 512MB file called .swapfile on your root partition, makes it SWAP format and enables it as available system SWAP. An fstab entry is also added so that it’s mounted after a machine reboot.

You can find more detailed instructions and explanations on this blog post. With some file systems, fallocate may not work – again, take a look at  this for a work around.


  • 4

How To Find Your Public IP Address From The Terminal

Tags :

Category : How-to

Get Social!

ip-address-deconstructionFinding the IP address of your local machine couldn’t be easier – ipconfig on Windows or ifconfig on Linux will bring up all of your local network interfaces and list the IP addresses associated with them. Finding out your public IP address, which is the IP addresses associated with your internet connection can be a little more tricky.

Whatsmyip will show your your public IP address on their webpage when you visit them. Perhaps more interestingly, when visited with Linux curl or wget only the IP public address is displayed without any HTML or other content around it.

You can therefore use curl to read your public IP address into a variable, and then use it in as you need to.


  • 0

My Proxmox VE Bash Scripts on GitHub

Category : Knowledge

Get Social!

octocat-githubI’ve created a public repository on GitHub with few Bash scripts which may (or may not) be helpful for anyone administering a Proxmox VE Server.

I’ll add to this repository over time with any new scripts I write. Let me know if they are useful, or if you have any of your own in the comments.

Currently the scripts are:

  • backup-all – will backup all OpenVZ Containers on the Proxmox cluster.
  • ct-disk-space – a print out of the diskspace used by all OpenVZ Containers on the server.
  • migrate – will migrate a Container to a different storage ID.
  • restore-all -will restore all OpenVZ Containers on a cluster to the latest available backup.

Link to GitHub proxmox-scripts repository: https://github.com/JAC2703/proxmox-scripts


Visit our advertisers

Search

Visit our advertisers