9月 262014

Last week, I was very honored to get sponsored to participate the Hanoi SFD 2014. I joined the Fedora meetup on Friday and gave a talk on Saturday. Below is the full report.

Day 0 (2014-09-18): Arrival Day

I left Beijing early in the morning and in the afternoon stayed in Hong Kong Airport to transfer. The flight to Hanoi was a bit late, and I arrived at the Hanoi Airport at around 8:00 PM (local time, 9:00 PM in Beijing time). The weather was wet and hot, but the people are nice. It took me some time to find a large shuttle bus, rather than the minibus. On the bus I met a Japanese guy, and it turned out he lived in a hotel not far from mine. So after getting off the bus, we walked to our hotels together most of the way.

It was about 10:00 PM when I arrived at the hotel. I shared a room with Sarup (banas), and he told me they (Thang, Somvannda, Tuan and others) would like to have me together go out for beer. I was a bit tired after the long trip, but after ten minutes’ rest, I joined them. Thang carried me on his motorbike to a street corner nearby, and I met Tuan (for the first time) and Somvannda (for the second time). I was surprised to find many people are there on the street at first. But I soon realized having cool beer outside is the best way to pass the hot night. By cool I mean not only temperature (ice beer), but also the taste (nice beer).

Day 1 (2014-09-19): Fedora Meetup

On Friday morning we went to the VAIP office and had a Fedora APAC ambassador meetup the whole day. The meetup was set up for APAC ambassadors to discuss critical tasks. EMEA has had a lot of similar meetups, but for APAC, it was the first to my knowledge. (It was at least the first in this year.) To include remote participants who cannot make it at Hanoi, we also joined the #fedora-apac IRC channel. There we met gnokii, kushal, FranciscoD, etc. We also set up a pad on PiratePad.

In the morning, we discussed many issues including the budget status, current issues and so on. It seems the major issue is that not many APAC ambassadors are active, and people do not regularly attend meetings. In China, the state is somewhat better: we do have a few active contributors and we managed to have regular IRC meetings and offline activities (release parties every release, yearly FAD, and FUDCon Beijing). In India there is another problem: there might be too many ambassadors and some people tend to use Fedora as a travel agency. We agreed that people need actively participate biweekly meetings and mailing list discussions to get their tickets approved easily, and to be considered as active, one ambassador needs to organize (or help organize) at least one event per year.

We also talked about the FAD Phnom Penh under planning and the ambassador Polo shirts. The FAD planning is generally in good shape. I saw no Taiwan ambassador registered the event but I think they should consider. Regarding the Polo shirts, unfortunately the Fedora logo on the sample shirt is incorrect and needs to be fixed. And the quality of the shirt is not quite high. I am supposed to ask local vendors in China to see if we can get better ones within a reasonable price. We went on to discuss general swag production issues. gnokii suggested that good quality can be produced in Europe for both EMEA and APAC regions. Besides, China can be one good candidate among the locations to store the swag.

I also learned from Tuan about why we APAC folks lose some money when getting reimbursed by paypal while Americans not. The reason is that US paypal accounts have the option to cover the transaction fee by the sender, while other accounts do not. So the fee is charged at the receiver side, causing the loss. To walk around the issue, we might let APAC CC holder izhar set up a US paypal account.

In the afternoon, after a short pizza lunch, we carried on remaining tasks. We spent quite some time in summarizing the budget usage in previous quarters. It was sad to find that none of the planned events in Q2 happened at last. To solve the budget problem, we adjusted the budget allocation for the remaining quarters, and came up with ideas of possible events. After that, we talked about Fedora sessions for the SFD next day. At last, Somvannda asked us to share stories of being an Fedora ambassador. For me, it was the simple idea of organizing regular events to gather existing contributors and attract newcomers, and the idea of starting something by oneself when no one else has started it.


In the evening, we went to see the water puppet show, which is fun and amazing. At dinner we had delicious dishes and noodles, and Saigon beer! But we did not stay up too late at night, since we felt quite tired after one day’s meeting, and we need to prepare for SFD in the next day.

Day 2 (2014-09-20): Hanoi SFD 2014

Saturday was the Software Freedom Day (SFD), a global event to celebrate Free and Open Source Software (FOSS). I organized SFD in Tsinghua University last year, and it is lucky for me to be part of SFD Hanoi this year. Hanoi SFD is organized by VFOSSA, the FOSS association in Vietnam. Fedora was one main sponsor of the event. It was a whole day event held in a university. So many volunteers are students and employees of the university. It was fun that the event begins with volunteers dancing, both in the morning and in the afternoon, and they are so good at it!

In the morning are welcome and keynote sessions in one large lecture hall. Sarup, Somvannda, and I are honored to be introduced as special international guests to the event (in English). They awarded new members and event sponsors in the welcome session. Later in the keynote session, Tuan delivered a speech on seven ways to contribute to Fedora (without coding). Most of the morning sessions were in Vietnamese, and I could only understand a little bit. I brought some Fedora 20 DVDs, stickers, and flyers from China, and they were distributed very soon at the booth.


In the afternoon, we had a dedicated room for Fedora related sessions. First, Thang gave a general introduction of the Fedora Project to the audience in Vietnamese. Then I talked about free and open source software defined radio (FOSS SDR). With a lot of examples, I introduced why we should have FOSS SDR, and how FOSS SDR can enable hacking in the radio frequency. I introduced GNU Radio and various SDR hardware such as HackRF and bladeRF to show how FOSS and open hardware play well with each other. Since the talk was in English, and the topic is not so familiar, the main purpose of the talk was to show the power of FOSS and open hardware, and to encourage the audience to try out and contribute to FOSS projects.


Later on, Sarup delivered a FOSS 101 talk. He talked about why we should choose FOSS, how newcomers join and contribute to Fedora, and main communication tools of FOSS communities. Then he gave an introduction on Git and version control concepts. I helped demonstrate the git operations, and Trang helped translate for easy understanding.

At around 4:00 PM, we gathered to one room again. There was a panel Q&A session followed by the lucky draw. The panel session was quite interactive, and the audience raised many questions. One interesting thing is that the panel speakers voted for the best question and there was an award for that questioner. Then in the lucky draw, it turned out we foreigners were not so lucky. None of us was chosen. But lucky draw is always fun for everyone.

In the evening, we had dinner with the organizers and volunteers of SFD. We drank beer and toast to each other. I even learned how to toast in Vietnamese!

Day 3 (2014-09-21): One Day Tour

On Sunday, Somvannda and Sarup left for the airport early in the morning. My flight was around at 7:00 PM, so I took a one day tour in Hanoi. I visited Quang Truong Ba Dinh (Ba Dinh Square), Ho Chi Minh’s Stilt House, Ho Chi Minh Museum, One Pillar Pagoda, the Flag Tower, Hanoi Cathedral, and so on. The sight spots are relatively near to each other, so I travelled around mostly by walking. I had lunch at Quan An Ngon, a popular restaurant in Hanoi, and bought some candies and gifts to bring back to China. In the afternoon, on the way back to the airport, I also walked by the Ho Hoan Kiem (Hoan Kiem Lake). The sight spots are nice, and the food is delicious. So I enjoyed the trip to Hanoi a lot. Plus the warm support and help from Tuan, Thang, Somvannda, Sarup, and others, the days in Hanoi are quite memorable to me.

8月 072014

最近,我发现 Fedora 系统上没有 plugdev 群组,而是使用动态 ACL 的方式允许普通用户访问可插拔设备等。

事情的缘由是我在折腾软件无线电 (SDR),更特别的说就是 bladeRF,它在编译安装时会自动安装相应的 udev 规则,以使得普通用户可以访问这块板卡。它提供的 udev 规则文件为 /etc/udev/rules.d/88-nuand.rules,内容如下:

# nuand bladeRF
ATTR{idVendor}=="1d50", ATTR{idProduct}=="6066", MODE="660", GROUP="plugdev"

# Reserved for future bladeRF-specific bootloader
ATTR{idVendor}=="1d50", ATTR{idProduct}=="6081", MODE="660", GROUP="plugdev"

# Cypress Bootloader
ATTR{idVendor}=="04b4", ATTR{idProduct}=="00f3", MODE="660", GROUP="plugdev"

其含义是将 bladeRF (以及相关设备)的权限设为仅属主和群组可读写,群组设为 plugdev。类似的使用 plugdev 群组的 udev 规则设置,在许多涉及可插拔外设的上游项目里都会看到。

然而事实上 Fedora 系统上是没有 plugdev 群组的。bladeRF 维基建议手动建立该群组,并将当前用户添加进去。 但这种做法其实是不被 Fedora 推荐的,原因是这种静态的设备管理群组

  • 不安全。考虑这样的一个场景:一个 SSH 远程登录的用户可以访问物理主机的摄像头、麦克风,只要他是该群组的成员。
  • 不灵活。需要手动地维护该群组的成员列表,新增用户还需要注销当前会话重启会话才能使用该设备。
  • 不具体。plugdev 群组的用户可以使用任何可插拔设备,不论这个设备是手机、摄像头还是麦克风。

Fedora 支持动态的权限控制 (ACL),可以根据用户会话状态、物理座位(seat)配置来决定是否授权设备。在这种机制下,udev 规则文件可以是简单的一行

SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", \
  ATTRS{idVendor}=="1ed8", ATTRS{idProduct}=="000[456]" \

这里的 ID_<some_name> 是设备的一个“合适”的类别,例如 ID_CDROM, ID_MEDIA_PLAYER 等。它会出现在 Systemd 的 uaccess 规则文件 70-uaccess.rules 中,这个文件会授权此类设备给活跃用户。

遗憾的是,目前 uaccess 规则文件里并没有一个软件无线电有关的设备类别。所以暂时只能像如下的 udev 规则文件中那样,直接给设备加上 uaccess 的标签:

SUBSYSTEM!="usb", GOTO="nuand_rules_end"
ACTION!="add", GOTO="nuand_rules_end"

ATTR{idVendor}=="1d50", ATTR{idProduct}=="6066", TAG+="uaccess"

# Reserved for future bladeRF-specific bootloader
ATTR{idVendor}=="1d50", ATTR{idProduct}=="6081", TAG+="uaccess"

# Cypress Bootloader
ATTR{idVendor}=="04b4", ATTR{idProduct}=="00f3", TAG+="uaccess"


注意 udev 规则文件命名时开头的数字编号需要小于 70,此时 uaccess 才会生效。如果设备已经连接到电脑上,要使新添加的或新修改的规则生效,还需要 udevadm trigger 一下。

事实上,邮件列表并不推荐上述做法,udev 与 Systemd 开发者 Kay Sievers 表示设备规则文件不应该直接设置 uaccess 这一标签。我已经在 systemd-devel 邮件列表上请求添加一个软件无线电相关的设备类别,得到了肯定的回应,并最终在这次提交中添加了 ID_SOFTWARE_RADIO。在不远的将来,带有这一改动的 Systemd 进入主流发行版后,我们将可以通过在 udev 规则文件中使用类似 ENV{ID_SOFTWARE_RADIO}="bladerf" 的语句,让普通用户以一种更安全灵活的方式使用软件无线电外设。

9月 272013

Note: For the Chinese version of this report, please refer to this page.

On last Saturday (Sep 21), the Software Freedom Day Activity at Tsinghua University was held. It was hosted by Tsinghua University Network Administrators (TUNA) with the assistance of Beijing GNOME User Group (BJGUG). There were more than 60 attendees. The onsite registration began at about 2 pm, and it was done on a laptop computer running LibreOffice Calc. The spreadsheet would be used by the lucky draw in the end. We prepared CDs, stickers, and posters, which were readily available for every registrants.

The formal event started at about 2:30 pm with the welcome speech by me (alick). I introduced what software freedom day (SFD) is and what free software is. I also introduced the event host and sponsors. This event was sponsored by Mozilla, COPU, GitCafe, CodeWeavers, Linux Deepin, and Fedora community. They provided many kinds of swag as gifts. Besides Mozilla also covered the cost of SFD posters and so on. I also introduced the NITE-LPI certificate program supported by COPU.

Alick introduces free software

Alick introduces free software

Following was three speeches. The first one was “GNOME Shell” by Li Bin, the current BJGUG leader. He talked about components of GNOME Shell and its flexible and powerful extension capability, and then demonstrated the development of GNOME Shell extensions. gnome-tweak-tool and https://extensions.gnome.org/ was introduced during the talk. The main programming language used to develop a GNOME Shell extension is Javascript. With the help of gnome-shell-extension-tool, an extension can be created rapidly.

GNOME Shell by Li Bin

GNOME Shell by Li Bin

Next was the talk “Firefox & Firefox OS” by Yuan Xulei, who is an engineer from Mozilla. He introduced the features of Firefox, and explained in details how to use addon to customize Firefox and improve the web browsing experience. Later on he talked about Firefox OS, a new open source mobile operating system by Mozilla based on Linux and Gecko technologies.

Firefox OS by Yuan Xulei

Firefox OS by Yuan Xulei

After a short break, Zhou Jianfeng, a teacher from Center for Astrophysics, Tsinghua University, gave the speech titled “Airelinux”. He first introduced Astrophysical Integrated Research Environment (AIRE), and then talked about the goal and plan of Airelinux project. Airelinux is a new Linux distribution targeted to high performance computing in astrophysics. Please join it if you are an enthusiastic astronomer, or active in the community of free software (esp. Debian), or an artist who can help with the artwork design!

Airelinux by Zhou Jianfeng

Airelinux by Zhou Jianfeng

There was five minutes QA for each talk. Gifts such as Firefox toys, notebooks, cups, and mouse pads were distributed.

After the speeches was the parallel demo, Hackfest and Installfest session. Small groups were formed and there were face to face talks. There were two demonstrations. One is brought by Fedora community, where Gerard, a Fedora ambassador, talked with people and encouraged them to join Fedora project. Three Fedora T-shirts were distributed. Another demo was for LPI certificate program, where Wang Yun, the country manager of LPI, explained it to interested people. The hackfest was an software defined radio experiment conducted by Wang Kang (scateu), where data was transmitted between the audio interface, and gMFSK was used to modulate/demodulate on the PC. It was quite attractive to the audience.

At about five o’clock, we had the lucky draw. It was a cute web interface, implemented in Python by Justin Wong (bigeagle). In the lucky draw 3 T-shirts and 5 CrossOver license codes were distributed. At last we had group photos.

Group photo

Group photo

The links to the slides and videos of speeches are available on the SFD Wiki page. The photos can be found at G+ pages. And as a final note, we encourage every attendees to leave your feedback when you got the email notice for the post event survey!

9月 252013

上周六(9 月 21 日)北京天气晴好,由清华大学学生网管会 (TUNA) 主办,并由北京 GNOME 用户组 (BJGUG) 协办的自由软件日清华站活动顺利举行。活动有超过 60 人参加。接近下午两点时开始现场注册,这次活动的注册为电子注册,每个人在注册电脑上的 LibreOffice 表格中填写各自的信息,这个表格会被最后幸运抽奖的程序直接读取。我们准备了光盘、贴纸与宣传海报,注册后每人都可以领取。

活动正式开始于大约两点半。开场时由我(赵涛)致欢迎辞。我在欢迎辞中介绍了什么是自由软件日活动、什么是自由软件,此外介绍了活动的主办方和赞助单位。本次活动得到了谋智网络 (Mozilla)、中国开源软件推进联盟 (COPU)、GitCafe、CodeWeavers、深度 Linux、Fedora 社区等的大力支持,他们为本次活动提供了丰富多样的礼品,其中 Mozilla 还对活动宣传品等的开销提供支持。我还对 COPU 支持的 NITE-LPI 联合认证项目做了介绍。



之后便开始了主题演讲环节。第一个演讲由 BJGUG 主席李彬带来,题为“GNOME Shell”。李彬在演讲中介绍了 GNOME Shell 的组成,灵活强大的扩展 (extension) 机制,还现场演示了扩展开发。演讲中推荐了 gnome-tweak-tool 和 https://extensions.gnome.org/ 网站。GNOME Shell 扩展开发主要使用 Javascript,借助于已有的扩展框架生成工具 gnome-shell-extension-tool,扩展可以很快捷地被开发出来。

李彬介绍 GNOME Shell

李彬介绍 GNOME Shell

紧接着是来自 Mozilla 的工程师袁徐磊带来的“Firefox & Firefox OS”。他介绍了流行的开源浏览器火狐 (Firefox) 的特性。使用附加组件 (addon) 定制 Firefox,改善网页浏览体验是 Firefox 的一大特点,袁徐磊对此做了详细讲解。他还对 Mozilla 新推出的基于 Linux 和 Gecko 技术的开源移动操作系统 Firefox OS 的发展和开发平台做了介绍。

袁徐磊介绍 Firefox OS

袁徐磊介绍 Firefox OS

短暂的中场休息后,来自清华大学天体物理中心的周建锋老师做了题为“Airelinux”的演讲。他首先介绍了天体物理集成研究环境 (Astrophysical Integrated Research Environment) 即 AIRE,继而介绍了 Airelinux 项目的目标和计划。Airelinux 是一个新的面向天文学计算的 Linux 发行版项目,欢迎广大天文爱好者、自由软件社区贡献者(特别是 Debian 贡献者)、以及设计人员的加入。

周建锋介绍 Airelinux

周建锋介绍 Airelinux


主题演讲环节之后,是并行的展台展示、Hackfest、Installfest 环节,这个环节大家分成若干小组,进行面对面的交流。展台有两个,其一是 Fedora 社区的展示,Fedora 大使吉拉德 (gbraad) 在现场和大家做了深入交流,鼓励大家加入 Fedora 项目,并送出了 3 件 Fedora T 恤。另外一个展台是对 LPI 认证项目的介绍,LPI 中国区经理王雲老师为大家做了答疑解惑,她表示今后会在高校做更多的活动介绍 LPI 项目。Hackfest 则是有王康带来的软件无线电实验。这个实验用声卡进行信息传输,在电脑上用 gMFSK 做调制解调,使现场同学领略到了软件无线电的魅力。

五点左右时,活动来到了最后的幸运抽奖环节,抽奖程序是一个卖萌的网页界面,主体逻辑由 Python 语言实现,作者是 Justin Wong (bigeagle)。我们抽奖送出了 3 件 T 恤衫和 5 个 CrossOver 正版序列号,其中序列号在活动后邮件送出。活动最后大家合影留念。




活动演讲的讲稿链接、演讲视频的优酷链接可以在维基页面上找到。活动照片请看 G+ 页面。最后,感谢所有到场人员的热情参与,请参加活动的朋友收到活动调查问卷的邮件通知后留下您的宝贵意见。