Along with rewrite and proxy, redirect is another similar term.

Redirect: give user a new adress (User knows)

Rewrite and proxy both can map user requests to internal resources. (User does not know)

Rewrite is more flexible to map requests, wheras proxy is more straightforward.

Content about it may be added in the future!

Sometimes, RStudio server always stuck in the loading page, especially exiting abnormally in last run. Use systemctl restart rstudioserver or restart docker do not solve the problem. The reason is that Rstudio automatically resume the last running environment. However, when something wrong, Rstudio always try to resume a bad environment in a dead loop.


Delete cached session files.

~/.local/share/rstudio/session (update version)

~/.rstudio/session (old version)

Nomenclature of gene has a long history.

Take an id with the name. That will guarantee most gene matched.

Last time, I was reading three large tab delimited files into R (4.0.X) using read.table().

1st: 1.2M rows

2nd: 0.8M rows

3rd: 0.3M rows

The function did not fully parse the first file, and only 0.3M rows were susscefully read into memory. No problem was identified in the latter two files. I did not find any support documentation to elucidate the n_max behavior.

read.delim and read_delim(tidyverse) did fully parse the files.

read.table is NOT recommended!

Excel automatically formats characters looks like date or time.

Some IDs, such as PDB ID and gene name, contain characters looks like date. However, Excel is the most efficient tools to quickly view the dataset, especially when datasets is small (<10000 rows).

A practical way is to open a blank Excel file, import the data file, and specify fields as text.

Among these popular Cloud Drive service providers, Dropbox is the only one offering official Linux client. However, errors wll pop up when starting the service. The reason is some dependencies missing in Ubuntu 20.04.


sudo apt install libc6 libglapi-mesa libxdamage1 libxfixes3 libxcb-glx0 libxcb-dri2-0 libxcb-dri3-0 libxcb-present0 libxcb-sync1 libxshmfence1 libxxf86vm1

The Dropbox will generate a unique one-time link, and user need to copy this link into a browser to authorize the action.

Once the service running, the Dropbox will sync your library under the home folder.

Create Git repo in Rstudio

Create repo in Github

git config --global user.name "lyjspx"

git config --global user.email "lyjspx@126.com"

git remote add origin https://github.com/lyjspx/PROTAC.git
git pull --set-upstream origin main
git add . && git commit -m "initial commit" && git push -u origin main

To be completed

Host directory can be mounted to a container at read-lony or read-write mode.

It looks like LXD officially support one-step configuration from some time. In the previous version, we have to go through serveral steps to mount it in read-write mode. See the conversations.

Previous version - Example

Now, we can easily define the mounting mode by tuning readonly flag.

lxc config device add container name disk source=/data path=/mnt/data readonly=true

Docker run errors in LXD container

docker: Error response from daemon: failed to create shim: OCI runtime create failed: container_linux.go:380: starting container process caused: process_linux.go:545: container init caused: rootfs_linux.go:76: mounting "proc" to rootfs at "/proc" caused: mount through procfd: permission denied: unknown.
This is resulting from the security setting of LXD container.


For new container:
lxc launch ubuntu  -c security.nesting=true
For a currently running container:
lxc stop container

lxc config set container security.nesting true

lxc start container

Launch docker container

docker run -d -ti  --rm -p 8787:8787 -e ROOT=TRUE  -e PASSWORD=yourpasswordhere --name RStudioServer --mount source=R_data,target=/home/rstudio/rdata  rstudio

-d: detach

-t: psudo-terminal

-i: interactive

–rm: clean up

Port forwarding of the host

lxc config device add mycontainer myport80 proxy listen=tcp: connect=tcp: