Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Fuck you, Dropbox!
# Starting October 15, Dropbox has fucked all his CentOS 6 (and many other) users
# by changing OS requirements:
# ----
# We are reaching out to let you know that device(s) which do not meet our new
# operating system requirements have been logged out of the Dropbox desktop
# application. Dropbox has ended support for Ubuntu 13.10 and below, and Fedora 20
# and below.
# ...
# Your device(s) must now be on glibc 2.19 or higher to log back into the Dropbox
# desktop application
# ----
#
# Here is the instruction on how to sort it out w/o migrating to "supported" OSes
# Thanks tacvbo for his post:
# https://www.dropboxforum.com/t5/Syncing-and-uploads/Dropbox-client-warns-me-that-it-ll-stop-syncing-in-Nov-why/m-p/303208/highlight/true#M45240
#
# This instruction should be improved though to support Dropbox autoupdates
#
# become root
sudo bash
# Install latest stable kernel (4.x)
rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
rpm -Uvh https://www.elrepo.org/elrepo-release-6-8.el6.elrepo.noarch.rpm
yum-config-manager --enable elrepo-kernel
yum install kernel-ml.x86_64
# modify /etc/grub.conf and reboot into the new kernel
# install new kernel headers and selinux libs into a non-system location
yumdownloader kernel-ml-headers.x86_64
rpm -ihv -r /opt/kernel-ml-headers kernel-ml-headers-4.18.14-1.el6.elrepo.x86_64.rpm
yumdownloader libselinux-devel
rpm -ihv -r /opt/kernel-ml-headers libselinux-devel-2.0.94-7.el6.x86_64.rpm --nodeps
# install gcc 7.3 and patchelf
yum install centos-release-scl patchelf
yum-config-manager --enable rhel-server-rhscl-7-rpms
yum install devtoolset-7
# enable gcc 7.3 and other related stuff
scl enable devtoolset-7 bash
# install latest bison
wget https://ftp.gnu.org/gnu/bison/bison-3.0.4.tar.gz
tar zxf bison-3.0.4.tar.gz
cd bison-3.0.4
./configure --prefix=/opt/bison-3.0.4
make
make install
# prepare new glibc configs
mkdir -p /opt/glibc-2.27/etc/ld.so.conf.d
cp /etc/ld.so.conf /opt/glibc-2.27/etc/
cp /etc/ld.so.conf.d/kernel-ml-4.18.14-1.el6.elrepo.x86_64.conf /opt/glibc-2.27/etc/ld.so.conf.d
# build and install the new glibc
wget https://ftp.gnu.org/gnu/glibc/glibc-2.27.tar.gz
tar xzvf glibc-2.27.tar.gz
cd glibc-2.27
mkdir build
cd build
PATH=$PATH:/opt/bison-3.0.4/bin ../configure --prefix=/opt/glibc-2.27 --with-headers=/opt/kernel-ml-headers/usr/include
PATH=$PATH:/opt/bison-3.0.4/bin make
PATH=$PATH:/opt/bison-3.0.4/bin make install
# become a user who needs to run dropbox
su - user
# install and patch dropbox binary
wget -O - "https://www.dropbox.com/download?plat=lnx.x86_64" | tar xzf -
patchelf --set-interpreter /opt/glibc-2.27/lib/ld-2.27.so ~/.dropbox-dist/dropbox-lnx.x86_64-59.4.93/dropbox
patchelf --set-rpath /opt/glibc-2.27/lib ~/.dropbox-dist/dropbox-lnx.x86_64-59.4.93/dropbox
# install required libs
ln -s /lib64/libgcc_s.so.1 .dropbox-dist/dropbox-lnx.x86_64-59.4.93/
ln -s /usr/lib64/libstdc++.so.6 .dropbox-dist/dropbox-lnx.x86_64-59.4.93/
ln -s /lib64/libz.so.1 .dropbox-dist/dropbox-lnx.x86_64-59.4.93/
ln -s /lib64/libgthread-2.0.so.0 .dropbox-dist/dropbox-lnx.x86_64-59.4.93/
ln -s /lib64/libglib-2.0.so.0 .dropbox-dist/dropbox-lnx.x86_64-59.4.93/
# make sure you have dropbox.py in the path
# (https://www.dropboxwiki.com/tips-and-tricks/using-the-official-dropbox-command-line-interface-cli)
# run dropbox
LD_LIBRARY_PATH=~/.dropbox-dist/dropbox-lnx.x86_64-59.4.93 dropbox.py start
# check the status
dropbox.py status
Syncing 525 files
Downloading 525 files...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.