Monday, November 29, 2021

Share Folder in Mac with Multipass Ubuntu Instance

 Share Folder


multipass mount local/folder/path multipass-instance-name

multipass mount /Users/bparanj/cloud gold


multipass info gold

Name:           gold

State:          Running

IPv4:           192.168.64.2

Release:        Ubuntu 20.04.3 LTS

Image hash:     91740d72ffff (Ubuntu 20.04 LTS)

Load:           0.71 0.53 0.32

Disk usage:     2.6G out of 4.7G

Memory usage:   241.0M out of 981.3M

Mounts:         /Users/bparanj/cloud => /Users/bparanj/cloud

                    UID map: 501:default

                    GID map: 20:default

Saturday, November 27, 2021

ssh into multipass instance

 Launch Ubuntu instance:

multipass launch --name gold   

Copy the IP address from:

multipass list 

Log in to multipass instance:

sudo ssh -i /var/root/Library/Application\ Support/multipassd/ssh-keys/id_rsa ubuntu@192.168.64.2



Friday, November 19, 2021

Tuesday, November 09, 2021

Postgresql Post Install Message

 To migrate existing data from a previous major version of PostgreSQL run:

  brew postgresql-upgrade-database


This formula has created a default database cluster with:

  initdb --locale=C -E UTF-8 /opt/homebrew/var/postgres

For more details, read:

  https://www.postgresql.org/docs/14/app-initdb.html


To restart postgresql after an upgrade:

  brew services restart postgresql

Or, if you don't want/need a background service you can just run:

  /opt/homebrew/opt/postgresql/bin/postgres -D /opt/homebrew/var/postgres


Zoom Link:

sqlite3 install

After brew install, the output: 

If you need to have sqlite first in your PATH, run:

  echo 'export PATH="/opt/homebrew/opt/sqlite/bin:$PATH"' >> ~/.zshrc


For compilers to find sqlite you may need to set:

  export LDFLAGS="-L/opt/homebrew/opt/sqlite/lib"

  export CPPFLAGS="-I/opt/homebrew/opt/sqlite/include"


For pkg-config to find sqlite you may need to set:

  export PKG_CONFIG_PATH="/opt/homebrew/opt/sqlite/lib/pkgconfig"

Monday, November 08, 2021

Warning! PATH is not properly set up

Warning! PATH is not properly set up, /Users/n1576925/.rvm/gems/ruby-3.0.2/bin is not at first place.

         Usually this is caused by shell initialization files. Search for PATH=... entries.

         You can also re-add RVM to your profile by running: rvm get stable --auto-dotfiles

         To fix it temporarily in this shell session run: rvm use ruby-3.0.2

         To ignore this error add rvm_silence_path_mismatch_check_flag=1 to your ~/.rvmrc file.


In MacOS Monterey, add the following to .bash_profile:


# RVM can encounter errors if it's not the last thing in .bash_profile

export PATH="$PATH:$HOME/.rvm/bin" # Add RVM to path for scripting (to manage Ruby versions)

export PATH="$GEM_HOME/bin:$PATH"


[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*


The .zshrc has only one line:

source ~/.bash_profile