Local tracks on GBIC

56 views
Skip to first unread message

Sebastien Weyn

unread,
Mar 22, 2018, 12:47:17 PM3/22/18
to genome...@soe.ucsc.edu
Hello,

I am attempting to host local tracks on GBIC.

We are hosting on AWS EC2, and I have run the following steps:

# download full mirror
sudo bash ~/browserSetup.sh -u mirror mm10
sudo bash ~/browserSetup.sh addTools
printf "db.user=browser\ndb.password=genome\ndb.host=127.0.0.1" > ~/.hg.conf; chmod 600 ~/.hg.conf

# manually configure /usr/local/apache/cgi-bin/hg.conf
defaultGenome=Mouse
db.trackDb=trackDb_local,trackDb



Initially, I tried to load a BED file using makefile

# download tools to load sql
mkdir src && cd src
wget https://raw.githubusercontent.com/ucscGenomeBrowser/kent/1b09e68a8fca8098b818be0586055c53549db384/src/hg/lib/trackDb.sql
wget https://raw.githubusercontent.com/ucscGenomeBrowser/kent/1b09e68a8fca8098b818be0586055c53549db384/src/hg/lib/hgFindSpec.sql
cd ..

# make ra files
mkdir -p tracks/mm10/
printf "include trackDb.RNAseq.ra" >> ~/tracks/mm10/trackDb.ra
touch ~/tracks/mm10/hgFindSpec_local.tab

#The makefile looks like this
sqlDir="/home/ubuntu/src/"
DB=mm10

all::
hgTrackDb . ${DB} trackDb_local ${sqlDir}/trackDb.sql .
hgFindSpec . ${DB} hgFindSpec_local ${sqlDir}/hgFindSpec.sql .

—> Running hgLoadBed and make seems to load the data properly into the database, but the tracks do not show up in the web view.



Interestingly, I also tried to rename (in MySQL) trackDb to trackDb_local and hgFindSpec to hgFindSpec_local. This did not affect browser functionality. However, creating a new table trackDb using "create table trackDb like trackDb_local” made (almost) all tracks disappear. Furthermore, then changing hg.conf to “db.trackDb=trackDb_local” caused the error "can not find any trackDb tables for mm10, check db.trackDb specification in hg.conf”.

Any help would be greatly appreciated.

Thanks,

Sebastien

P.S. Apologies for not purchasing a commercial license yet. We will do so as soon as we determine GBIC will work for us (as opposed to other setups) to avoid unnecessary complications for payments. We have not hosted any private data nor used it for any commercial purposes.


Disclaimer

The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.

Christopher Lee

unread,
Mar 26, 2018, 1:08:12 PM3/26/18
to Sebastien Weyn, genome...@soe.ucsc.edu
Hello Sebastien,

Thank you very much for your question about loading local tracks on
your mirror. Is there a particular reason you want local MySQL tables
and not hubs or bigBed/bigWig/BAM file tracks? It may be easier to
just use track hubs so you don't have to mess with loading and
maintaining a separate trackDb table.

Either way, I followed your steps and was able to successfully create
a local track:

# follow the steps but don't do the full mm10 mirror
$ sudo bash browserSetup.sh -b install
$ sudo bash browserSetup.sh -t main mirror mm10
$ sudo bash browserSetup.sh addTools
$ printf "db.user=browser\ndb.password=genome\ndb.host=127.0.0.1" >
~/.hg.conf; chmod 600 ~/.hg.conf
$ sudo vim /usr/local/apache/cgi-bin/hg.conf # manually configure
hg.conf with defaultGenome=Mouse and db.trackDb=trackDb_local,trackDb
$ mkdir src && cd src
$ wget https://raw.githubusercontent.com/ucscGenomeBrowser/kent/1b09e68a8fca8098b818be0586055c53549db384/src/hg/lib/trackDb.sql
$ wget https://raw.githubusercontent.com/ucscGenomeBrowser/kent/1b09e68a8fca8098b818be0586055c53549db384/src/hg/lib/hgFindSpec.sql
$ cd ..
$ mkdir -p tracks/mm10
$ printf "include trackDb.RNAseq.ra" >> ~/tracks/mm10/trackDb.ra
$ touch ~/tracks/mm10/hgFindSpec_local.tab
$ sqlDir="${HOME}/src"
$ DB=mm10

# make a one line bed file "chr1 1 10000"
$ vim mm10.bed
$ cat mm10.bed
chr1 1 10000

# load it and make sure it's there
$ hgLoadBed mm10 simpleTrack mm10.bed
$ hgsql -e "show tables mm10"

# make a simple ra file, which I assume you've already done?
$ vim tracks/mm10/trackDb.RNAseq.ra
$ cat tracks/mm10/trackDb.RNAseq.ra
track simpleTrack
type bed
shortLabel Very Simple track
longLabel Very Simple Track

# this change directory is missing from the users steps but I assume
they went here first?
$ cd tracks/mm10/
$ hgTrackDb . ${DB} trackDb_local ${sqlDir}/trackDb.sql .
$ hgsql -NBe "select * from trackDb_local" mm10
simpleTrack Very Simple track bed Very Simple Track 0 100 0 0 127 127
127 0 0 0 x 1 longLabel Very Simple Track\nshortLabel Very Simple
track\ntrack simpleTrack\ntype bed\n


After that I get a track called "My Simple Track" in the
"experimental" group of my mirror.

If you have any different steps than the ones above please let us know
and we'd be happy to help further!

Thanks,

Christopher Lee
UCSC Genomics Institute

Want to share the Browser with colleagues?
Host a workshop: http://bit.ly/ucscTraining

Thank you again for your inquiry and using the UCSC Genome Browser. If
you have any further questions, please reply to gen...@soe.ucsc.edu.
All messages sent to that address are archived on a
publicly-accessible forum. If your question includes sensitive data,
you may send it instead to genom...@soe.ucsc.edu.
> --
>
> ---
> You received this message because you are subscribed to the Google Groups
> "UCSC Genome Browser Mirror-Specific Support" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to genome-mirro...@soe.ucsc.edu.
> To post to this group, send email to genome...@soe.ucsc.edu.
> Visit this group at
> https://groups.google.com/a/soe.ucsc.edu/group/genome-mirror/.
> To view this discussion on the web visit
> https://groups.google.com/a/soe.ucsc.edu/d/msgid/genome-mirror/CF2ABD04-B72D-491D-BAC9-7FA5064D9487%40stoketherapeutics.com.
> For more options, visit https://groups.google.com/a/soe.ucsc.edu/d/optout.
Reply all
Reply to author
Forward
0 new messages