Skip to content

Instantly share code, notes, and snippets.

@kensipe
Last active July 20, 2020 17:00
Show Gist options
  • Save kensipe/fb4b784622abc540749f to your computer and use it in GitHub Desktop.
Save kensipe/fb4b784622abc540749f to your computer and use it in GitHub Desktop.
MapR Myriad Setup Notes
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv E56151BF
DISTRO=$(lsb_release -is | tr '[:upper:]' '[:lower:]')
CODENAME=$(lsb_release -cs)

Add the repository

echo "deb http://repos.mesosphere.io/${DISTRO} ${CODENAME} main" | sudo tee /etc/apt/sources.list.d/mesosphere.list
sudo apt-get -y update

sudo apt-get -y install docker.io
sudo apt-get -y install mesos

wget https://s3.amazonaws.com/downloads.mesosphere.io/master/ubuntu/14.04/mesos_0.22.0-0.1.20150218012319.ubuntu1404_amd64.deb
sudo dpkg -i mesos_0.22.0-0.1.20150218012319.ubuntu1404_amd64.deb

sudo stop mesos-master
export MASTER=10.240.16.219
sudo mkdir -p /etc/mesos-slave/attributes
echo $(hostname) | sudo tee /etc/mesos-slave/attributes/host
echo $(hostname -f) | sudo tee /etc/mesos-slave/hostname
echo $(hostname -i) | sudo tee /etc/mesos-slave/ip
echo manual | sudo tee /etc/init/mesos-master.override
echo "docker,mesos" | sudo tee /etc/mesos-slave/containerizers
echo "zk://10.240.16.219:2181/mesos" | sudo tee /etc/mesos/zk

sudo service mesos-slave restart

sudo apt-get install mapr-core mapr-fileserver
echo export MAPR_SUBNETS=10.240.0.0/16 | sudo tee -a /opt/mapr/conf/env.sh

dd if=/dev/zero of=/root/storagefile bs=1G count=20
echo /root/storagefile | sudo tee /tmp/disks.txt

sudo /opt/mapr/server/configure.sh -C $MASTER -Z $MASTER:2181 --create-user  -F /tmp/disks.txt

sudo /opt/mapr/server/configure.sh -C $MASTER -Z $MASTER:2181 -F /tmp/disks.txt

echo "*/1 *  *   *   *  root   /sbin/start mesos-slave >> /tmp/restart.log 2>&1" | sudo tee /etc/cron.d/mesos-slave-restart
echo "zk://$MASTER:2181/mesos" | sudo tee /etc/mesos/zk
sudo sed -i "1s/^/nameserver  $(MASTER)\n /" /etc/resolv.conf

sudo apt-get -y install mapr-core mapr-fileserver
echo export MAPR_SUBNETS=10.240.0.0/16 | sudo tee -a /opt/mapr/conf/env.sh

dd if=/dev/zero of=/root/storagefile bs=1G count=30
echo /root/storagefile | sudo tee /tmp/disks.txt

sudo /opt/mapr/server/configure.sh -C $MASTER -Z $MASTER:2181 --create-user  -F /tmp/disks.txt

sudo restart mesos-slave

sudo /opt/mapr/server/diskremove /dev/sdb

sudo /opt/mapr/server/configure.sh -C $MASTER -Z $MASTER:2181 -F /tmp/disks.txt

hadoop fs -ls /

sudo service mesos-slave restart

sudo maprcli node list -columns ip

1:
2: 10.240.174.234
3: 10.240.206.229

hadoop fs -rmr /user/mapr/terasort-output

sudo service mapr-warden restart
sudo maprcli node list -columns ip

 /opt/mapr/conf/mapr.login.conf
mapr-slave-2.c.massive-bliss-781.internal
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment