raynix 筆記

raynix 筆記

  • Home
  • WordPress Hosting
  • Side Quests
Illustration of a bird flying.
  • 关闭 Dell XPS 15 9550 的独立显卡

    最近我从 ebay 淘了个二手 Dell XPS 15 笔记本电脑, 2016年的而且配置很高, 但价格相当便宜. 既然好货不便宜, 这电脑是不是有问题? 是的, 卖家承认电脑的 nVidia 独立显卡有故障, 装好驱动程序之后 Windows 就会僵死, 但禁用了它之后一切正常, 当然就不要指望能玩什么像样的游戏了. 不过正好我也不打算在笔记本电脑上玩游戏的, 而且 Dell 对 Linux 的支持算是很好的, 于是我欣然买下. 电脑到手后我装了 Fedora 25, 一切顺利, 送走了 Windows 10. 顺便提及, Fedora 25 已经能检测到 XPS 15 BIOS 有更新可以安装了, 很赞. 启用 nVidia 驱动后果然死锁. 索性把 nVidia 关闭了吧, 还能延长电池的使用时间呢. 首先添加 bumblebee, 参考(在 Fedora 25…

    March 13, 2017
    Hardwares
    Fedora, nvidia, xps 15
  • Use MySQL Trigger To Do Incremental ETL

    There’s a huge MySQL table that I need to ETL to Google BigQuery daily, about 1 billion rows. The rows are updated in a random fashion all the time so I can’t do incremental ETL by the recording the max primary key. Then my colleague brought up the trigger idea, which I believe is the…

    February 3, 2017
    Systems Admin
    BigQuery, mysql
  • Saving Images in Chrome with Selenium

    Here’s how to save images in Chrome browser using Selenium. The API has element.screenshot_as_png() method but apparently it’s not implemented at the moment. With some minor changes to this answer I can save a image via the browser: 🙂

    January 31, 2017
    Opensource
    Chrome, Python, Selenium
  • Install OS X Sierra on VirtualBox on Ubuntu

    Following the guide below I installed Sierra in a VirutalBox VM running on Ubuntu quite easily. https://techsviewer.com/install-macos-sierra-virtualbox-windows/ Update: sample vboxmanage commands. vboxmanage modifyvm Sierra –cpuidset 00000001 000106e5 00100800 0098e3fd bfebfbff vboxmanage setextradata Sierra “VBoxInternal/Devices/efi/0/Config/DmiSystemProduct” “iMac11,3” vboxmanage setextradata Sierra “VBoxInternal/Devices/efi/0/Config/DmiSystemVersion” “1.0” vboxmanage setextradata Sierra “VBoxInternal/Devices/efi/0/Config/DmiBoardProduct” “Iloveapple” vboxmanage setextradata Sierra “VBoxInternal/Devices/smc/0/Config/DeviceKey” “ourhardworkbythesewordsguardedpleasedontsteal(c)AppleComputerInc” vboxmanage setextradata Sierra “VBoxInternal/Devices/smc/0/Config/GetKeyFromRealSMC” 1…

    January 18, 2017
    Systems Admin
    sierra, Ubuntu, VirtualBox
  • Install OS X Sierra on Proxmox

    My Proxmox running on an old Intel i7 has been upgraded to the latest: 4.4-5. When started the Sierra installer prepared following the above guide, the menu bar was stuck at “Language Chooser” which prevent the launch of DiskUtility or Terminal. The issue isn’t new and has its ticket here: https://github.com/kholia/OSX-KVM/issues/26 But I didn’t find…

    January 16, 2017
    Systems Admin
    proxmox, sierra
  • 尝鲜: Amazon Echo Dot

    圣诞节过后, 人们陆续的恢复上班了. 老板从美国给每个员工买了个 Amazon Echo Dot 作为礼物, 而这货还没有在土澳开卖,因此使用起来就有点别扭。 首先不管是 iPhone 还是 Android 手机,Alexa app 都不是可见的,除非账号所在地是在美国。我可以找个闲置的手机或者直接从第三方网站下载一个不受地域限制的 Alexa,但我发现通过浏览器设置并不需要假装在美国。我在浏览器里访问 Alexa.amazon.com,用自己的 Amazon 账号登录后,就可以安装提示设置我的 Echo Dot了,类似 Google Chrome cast 的设置过程。 Echo Dot 能做的事情很多,我就不重复了。目前我发现还不能把土澳的地址输入给它,因此天气预报基本上没法用了。听广播也是一样,貌似只能听美国的,不过美国的广播也还不错。由于家里没什么其他智能设备,例如灯泡,空调什么的,所以智能家居的功能我还没法测试。  希望 Echo Dot 早日正式登录土澳。当然还有 Google Home。

    January 15, 2017
    Hardwares
    Echo Dot, IoT
  • 快车道上的2016

    我们的2016年仿佛在快进模式中完成,简单回顾一下吧: 终于我们去了传说中的大洋路和12门徒!景色无比美丽,但苍蝇却着实多,估计是托附近众多农场的福。 工作方面,这是我丰收的一年。首先我完成了TB容量的数据库在线迁移,从美国加州某数据中心的服务器搬到AWS Aurora,让同事们基本上告别了数据库过载造成的麻烦,没用“完全”一词因为 Aurora 有时候也会被放倒。接下来的一个大项目可想而知,把私有云上的所有服务器搬家到AWS EC2。这两个项目就花了几个月,而且是我的前任以及前任的前任都没搞定的事情,因此我小小的有点自豪。有趣的是之前我们要求那个数据中心的工程师搭建一条数据中心到AWS的VPN专线,结果迟迟没有完成,这也是老板跟他们翻船的主要原因。后来我用了半天时间连读文档带执行就完成了AWS到公司局域网的VPN,我为自己的学习能力又稍微的自豪了一把。 另外一个大项目就是大数据仓储。公司之前使用 AWS Redshift,但性价比达不到要求。于是我接受了挑战,试用Google BigQuery,并把现有的为Redshift编写的程序和SQL改写一遍。改写还不算难,困难的是让新程序能把数据处理结果上传到BQ并保证两边的数据一致。比较数据也不难,做diff就是了,但30+TB的就不那么随便了,一旦一个月有那么几天的数据对不上,就要一个个环节的去排查。经过几个星期的排错,最后数据终于完全吻合了,100%吻合。BQ的优势相当明显,特别是对于不规律的大数据计算,用多少就付款多少,不需要评估CPU什么的。 其他琐碎的事情就不提了。 两个孩子各有进步。洋洋自打出院以后就很努力的吃饭和睡觉,体重慢慢接近中等水平了。笑笑的NAPLAN 考试成绩意外的好,因为我们俩关注她学习的时间无可奈何的很少。老婆给笑笑找了美术老师,一切都被她计划的很好,我给她点赞 🙂

    December 31, 2016
    Emerald Dreams
    2016
  • A Simple Python IO Trick

    I thought using Python’s gzip is quite straight forward, however the IO performance almost doubled with an extra BufferedWriter: import io import gzip def export_to_json_gz(schema): json_file = “test.json.gz” with io.BufferedWriter( gzip.open(temp_dir + json_file, ‘wb’) ) as gzfile: for row in stream_table_data(schema):       ujson.dump(row, gzfile, ensure_ascii=False)       gzfile.write(‘\n’) Now the bottle neck…

    December 12, 2016
    Python & Frameworks
    Python
←Previous Page
1 … 25 26 27 28 29 … 110
Next Page→
  • Eric Lin’s Blog
  • Eddie Wang’s Blog at WP
  • GoalKeeper’s Blog

raynix 筆記

Just another WordPress blog

  • Facebook
  • Twitter
  • Instagram

Proudly powered by WordPress