Tuesday, May 24, 2011

What is Android?

Beginning Android Gingerbread, Part 1

Beginning Android Gingerbread, Part 4


Q:

  1. What is Android?
  2. What is Dalvik?
  3. What is Gingerbread?
  4. What operating systems does Gingerbread/2.3.3 support?
  5. Does Gingerbread/2.3.3 support Java SE 6 APIs?
  6. Identify the three directories that are initially stored in the android-sdk-windows home directory.
  7. What is the difference between the SDK Manager and android tools?
  8. What does the emulator tool accomplish?
  9. When you start SDK Manager, what dialog boxes are presented?
  10. Which package is installed by default?
  11. What additional packages need to be installed so that you can develop with Gingerbread/2.3.3?
  12. Identify the directories that are added to android-sdk-windows as a result of installing Gingerbread/2.3.3. 

A:

1. Android is Google's operating system for mobile devices. It consists of an application framework, libraries, and a Dalvik
   virtual machine-based runtime environment that collectively run on top of a modified Linux kernel.

2. Dalvik is a non-Java virtual machine that's based on processor registers instead of a stack. It was created by Google
   employee Dan Bornstein, who named Dalvik after an Icelandic fishing village from where some of his ancestors originated.

3. Gingerbread is the nickname for version 2.3 of the Android platform and its 2.3.1 and 2.3.3 successors.

4. Gingerbread/2.3.3 supports the Windows XP (32-bit), Vista (32- or 64-bit), Windows 7 (32- or 64-bit), Mac OS X 10.5.8 or
   later (x86 only), and Linux (tested on Ubuntu Linux, Lucid Lynx) operating systems.

5. Gingerbread/2.3.3 does not support Java SE 6 APIs.

6. The three directories that are initially stored in the android-sdk-windows home directory are add-ons, platforms, and
   tools.

7. The difference between the SDK Manager and android tools is that SDK Manager lets you create AVDs, install SDK components,
   and more via a graphical user interface, whereas android lets you create Android projects, create AVDs, and more via a
   command-line-oriented user interface. Also, android presents SDK Manager's Android SDK and AVD Manager dialog box when
   invoked with no command-line arguments.

8. The emulator tool launches an AVD by creating a complete Android software stack down to the Linux kernel level; the
   emulated Android device includes preinstalled apps (such as Phone) that you can launch.

9. When you start SDK Manager, the Android SDK and AVD Manager dialog box, followed by the Refresh Sources and Choose
   Packages to Install dialog boxes are presented.

10. The Android SDK Tools, revision 10 package is installed by default.

11. The Android SDK Platform-tools, revision 3 and SDK Platform Android 2.3.3, API 10, revision 1 packages need to be
    installed so that you can develop with Gingerbread/2.3.3.

12. The platform-tools directory is added to android-sdk-windows and the android-10 directory is added to
    android-sdk-windows\platforms as a result of installing Gingerbread/2.3.3.

MAC hare - PC tortoise


Where in the world are Mac sales growing? Everywhere!
Mac is the hare, PC the tortoise... 


Business is booming: Apple MAC shipments to business were up 66% (vs. 4.5%) in March 2011.
Business sales in the December quarter, were up 65.4% (vs. 9.7%). 






Mac sales growth outpaced the Microsoft Windows PC market in the March quarter
-- the 20th quarter in row it has done so.



Friday, May 20, 2011

IBM greater than Microsoft

IBM Worth More Than Microsoft ?


For one brief, shining moment , IBM passed Microsoft  in stock-market capitalization. The folks at IBM have been keeping score ever since Mister Softy surpassed Big Blue as the biggest of the tech behemoths nearly 20 years ago.

not quite big surprise as long as 

let's remember that 
 and ...

Microsoft's biggest mobile money-maker is Android, not Windows Phone 7



Beginning of the end for Microsoft's Ballmer?

Plenty has gone wrong on Ballmer's watch --- Google became dominant on the Internet and mobile. Microsoft has become reliant on yesterday's technology ... 



FOR ITS PART, IBM IS ONE of the few pioneering computer companies to survive the transition from mainframes and mini-computers to the client-server era, which has been dominated by Microsoft and its Windows and Office software. IBM toiled in low-margin personal-computer hardware, while Gates & Co. profited from Microsoft's ubiquitous operating system. IBM eventually sold its PC business to China's Lenovo, increased investments in enterprise servers and storage and expanded heavily into higher-margin software and consulting services.

Thursday, May 19, 2011

FTP and e-mail on the same server

Setting up VSFTP using non-local users.


If an administrator wants for roadwarriors to set up on the same server
email and FTP , it's better that the FTP account has virtual users .

/etc/vsftpd/vsftpd.conf


local_enable=YES
write_enable=YES
local_umask=022
dirmessage_enable=YES
xferlog_enable=YES
connect_from_port_20=YES
xferlog_file=/var/log/vsftpd.log
xferlog_std_format=YES
chroot_local_user=YES
listen=YES
pam_service_name=vsftpd
userlist_enable=YES
tcp_wrappers=YES
# Virtual users will be logged into /home/virtualftp/[username]/
user_sub_token=$USER
local_root=/home/virtualftp/$USER
guest_enable=YES
guest_username=virtualftp
# Umask applied for virtual users and anon
anon_umask=0022
# Allows uploading by virtual users
anon_upload_enable=YES
# Allows creation of directories by virtual users
anon_mkdir_write_enable=YES
# Allows deletion of files and directories by virtual users
anon_other_write_enable=YES
# Sets a port range for passive mode. (must configure firewall to accept)
pasv_max_port=51123
pasv_min_port=51323
port_enable=YES
Setup virtual FTP usernames and their passwords (use the following format)
/etc/vsftpd/vsftpd_users.txt
username1
passwordforusername1
username2
passwordforusername2
username3
passwordforusername3
Build the vsftpd database
#db42_load -T -t hash -f /etc/vsftpd/vsftpd_users.txt /etc/vsftpd/vsftpd_users.db
#chmod 600 /etc/vsftpd/vsftpd_users.db /etc/vsftpd/vsftpd_users.txt
Create directories for each virtual FTP user
#mkdir -p /home/virtualftp/username1
Test an FTP virtual user login
#ftp localhost
Connected to localhost.
220 (vsFTPd 2.0.5)
Name (localhost:root): username1
331 Please specify the password.
Password:
230 Login successful.

Setting up VSFTPD permissions


I'm setting up a php-driven web app that serves files through a web interface. I've also set up a vsftp server to allow users to upload their data to a virtual directory. The vsftp server uses the pam-mysql module to use the web app's user database so no accounts are created on the system and we can disable ssh access.

Apache and vsftp run as different users , so we needed a way for each of them to view and edit the files created by the other. What we wound up doing was creating a group www-users and make it the group owner of /var/www. Then assigning the users apache and nobody to the group and set the permissons on the /var/www directory to 775. This will allow nobody and any other users in the www-users group to read and write to /var/www; it will also make it easier to authorize other users to write to /var/www — simply assign the user to the www-users group. Here are the steps in case any googlers need a hint.

1) set up vsftpd for umask 0027 (/etc/vsftpd.conf) [local_umask=0027]
2) create www-users group (groupadd www-users)
3) add user to group (usermod -a -G group user)
4) Set apache to run as www-users group (httpd.conf)
5) chgrp www-users /var/www
6) chmod 2775 /var/www
7) Add setgid permission to the directory: chmod g+s /var/www (I believe this is redundant)

Nokia must hide WP7

   In order to sell the phones with WP7 , Nokia will have to hide from the potential buyers the fact that its phones has a Windows operating system . So, why bother switching away from Symbian ?
Taking into account the fact that Microsoft and Nokia lost about half of the market share in one year , one can estimate that in the next year they can loose another half of what's left ...
So, it's probable that when Nokia will actually ship phones with WP7 , the combined market share of Nokia-Microsoft ECOSYSTEM will be aroud 10% ...
What will hapen with Windows 8 on ARM ? Will Microsoft advertise the fact that
you will spend less time with an ARM Windows 8 tablet ? ( in contrast with an iPad 3 )



Report warns Windows Phone 7 suffers from the "Your-dad-uses-it" syndrome

Gartner: Android and Apple win big globally in Q1

Microsoft sells 1.6 million Windows Phone 7 devices in Q1

Android, which Google executives said is being activated on 400,000 devices daily, tripled its market share from Q1 2010, with Samsung, HTC and Motorola shipping the lion's share of these phones.


Microsoft must adapt WP7 for tablets
So far, Microsoft has said that it plans to offer Windows Phone 7 on smartphones and Windows 7 on tablets. But that’s a mistake. As Apple and Google have shown, adapting smartphone-focused operating systems for tablets is actually a much better idea. Plus, with the growth of tablets in today’s marketplace, bringing Windows Phone 7 to slates might help improve the appeal of Microsoft’s operating system. The time has come for Microsoft to think seriously about bringing Windows Phone 7 to tablets.

Verizon HTC Trophy Windows Phone Can't Alter Microsoft's Prospects

 Microsoft’s Windows Phone sold 1.6 million units in the first quarter of 2011, according to new data from research firm Gartner. Although that pales in comparison with the number of Apple and Google devices activated during the same period, Microsoft executives’ traditional defense has been that Windows Phone is selling at a comparable rate to other first-generation platforms. 

FEDORA SENDMAIL SASLAUTHD

I configured a FEDORA 14 server with : SMTPAUTH and STARTTLS
I could send e-mails from a Windows Mobile 6.1 smartphone,
but with Thunderbird there was an error ;

On the Windows Mobile smartphone , the advanced settings were checked :
[ x ] Send/receive when I click send
[ x ] Require SSL for Incoming email
[ x ] Require SSL for Outgoing email
[ x ] Outgoing server requires authentication

In the end I changed MECH=shadow instead of MECH=pam , and
the problem was gone !



/etc/sysconfig/saslauthd
SOCKETDIR=/var/run/saslauthd


# Mechanism to use when checking passwords.  Run "saslauthd -v" to get a list
# of which mechanism your installation was compiled with the ablity to use.
# MECH=pam
MECH=shadow
# Options sent to the saslauthd. If the MECH is other than "pam" uncomment the next line.
# DAEMONOPTS=--user saslauth
# Additional flags to pass to saslauthd on the command line.  See saslauthd(8)
# for the list of accepted flags.
FLAGS=




http://www.howtoforge.com/howto_sendmail_smtp_auth_tls
http://www.screaming-penguin.com/node/4214
http://www.madboa.com/geek/sendmail-auth/
http://blog.mikezhang.com/2005/01/11/using-smtp-auth-and-starttls-with-sendmail




/etc/mail/sendmail.mc 

dnl ### do SMTPAUTH
define(`confAUTH_MECHANISMS', `LOGIN PLAIN DIGEST-MD5 CRAM-MD5')dnl
TRUST_AUTH_MECH(`LOGIN PLAIN DIGEST-MD5 CRAM-MD5')dnl


dnl ### do STARTTLS
define(`confCACERT_PATH', `/etc/mail/certs')dnl
define(`confCACERT', `/etc/mail/certs/cacert.pem')dnl
define(`confSERVER_CERT', `/etc/mail/certs/sendmail.pem')dnl
define(`confSERVER_KEY', `/etc/mail/certs/sendmail.pem')dnl
define(`confCLIENT_CERT', `/etc/mail/certs/sendmail.pem')dnl
define(`confCLIENT_KEY', `/etc/mail/certs/sendmail.pem')dnl
DAEMON_OPTIONS(`Family=inet, Port=465, Name=MTA-SSL, M=s')dnl




the full sendmail.mc 
~ ~ ~ 

divert(-1)dnl
include(`/usr/share/sendmail-cf/m4/cf.m4')dnl
VERSIONID(`setup for linux')dnl
OSTYPE(`linux')dnl
define(`confAUTH_MECHANISMS', `LOGIN PLAIN DIGEST-MD5 CRAM-MD5')dnl
TRUST_AUTH_MECH(`LOGIN PLAIN DIGEST-MD5 CRAM-MD5')dnl
dnl # do STARTTLS
define(`confCACERT_PATH', `/etc/mail/certs')dnl
define(`confCACERT', `/etc/mail/certs/cacert.pem')dnl
define(`confSERVER_CERT', `/etc/mail/certs/sendmail.pem')dnl
define(`confSERVER_KEY', `/etc/mail/certs/sendmail.pem')dnl
define(`confCLIENT_CERT', `/etc/mail/certs/sendmail.pem')dnl
define(`confCLIENT_KEY', `/etc/mail/certs/sendmail.pem')dnl
DAEMON_OPTIONS(`Family=inet, Port=465, Name=MTA-SSL, M=s')dnl
DAEMON_OPTIONS(`Family=inet, Name=MTA-v4, Port=smtp')dnl
FEATURE(`delay_checks')
define(`confDEF_USER_ID', ``8:12'')dnl
define(`confTO_CONNECT', `1m')dnl
define(`confTRY_NULL_MX_LIST', `True')dnl
define(`confDONT_PROBE_INTERFACES', `True')dnl
define(`PROCMAIL_MAILER_PATH', `/usr/bin/procmail')dnl
define(`ALIAS_FILE', `/etc/aliases')dnl
define(`STATUS_FILE', `/var/log/mail/statistics')dnl
define(`UUCP_MAILER_MAX', `2000000')dnl
define(`confUSERDB_SPEC', `/etc/mail/userdb.db')dnl
define(`confPRIVACY_FLAGS', `authwarnings,novrfy,noexpn,restrictqrun')dnl
define(`confAUTH_OPTIONS', `A')dnl
define(`confTO_IDENT', `0')dnl
FEATURE(`no_default_msa', `dnl')dnl
FEATURE(`smrsh', `/usr/sbin/smrsh')dnl
FEATURE(`mailertable', `hash -o /etc/mail/mailertable.db')dnl
FEATURE(`virtusertable', `hash -o /etc/mail/virtusertable.db')dnl
FEATURE(redirect)dnl
FEATURE(always_add_domain)dnl
FEATURE(use_cw_file)dnl
FEATURE(use_ct_file)dnl
FEATURE(`dnsbl',`sbl-xbl.spamhaus.org')dnl
FEATURE(`dnsbl',`list.dsbl.org', `"550 Mail from " $&{client_addr} " BLOCKED/DSBL; see http://www.dsbl.org/listing [dsbl.org]?" $&{client_addr}')dnl
FEATURE(`dnsbl',`bl.spamcop.net', `"550 Mail from " $&{client_addr} " BLOCKED/COP; see http://www.spamcop.net/w3m?action=checkblock&ip= [spamcop.net]" $&{client_addr}')dnl
FEATURE(`dnsbl',`cbl.abuseat.org')dnl
FEATURE(`dnsbl',`dnsbl.sorbs.net',`"554 Rejected " $&{client_addr} " Found in dnsbl.sorbs.net"',`t')dnl
FEATURE(`dnsbl', `bhnc.njabl.org', `"550 Mail from " $&{client_addr} " BLOCKED/BHNC; see http://www.njabl.org/lookup [njabl.org]?" $&{client_addr}')dnl
FEATURE(`dnsbl', `dul.ru', `Use mail relays of your ISP')dnl
FEATURE(`enhdnsbl',`multi.uribl.com', `"Spam blocked see: http://lookup.uribl.com/?"$&{client_addr}', `t')dnl
INPUT_MAIL_FILTER(`greylist',`S=local:/var/run/milter-greylist/milter-greylist.sock')
FEATURE(local_procmail, `', `procmail -t -Y -a $h -d $u')dnl
FEATURE(`access_db', `hash -T -o /etc/mail/access.db')dnl
FEATURE(`blacklist_recipients')dnl
EXPOSED_USER(`root')dnl
LOCAL_DOMAIN(`localhost.localdomain')dnl
MASQUERADE_AS(`grampa.com')dnl
MAILER(smtp)dnl
MAILER(procmail)dnl
dnl MAILER(cyrusv2)dnl
define(`confMAX_MESSAGE_SIZE',`12000000')dnl
INPUT_MAIL_FILTER(`clamav',`S=local:/var/run/clamav-milter/clamav.sock, F=, T=S:4m;R:4m')dnl
define(`confINPUT_MAIL_FILTERS',`clamav')

LUBUNTU - New Ubuntu Family Member



It's official: Lubuntu is an official Ubuntu derivative
and is mainly geared toward low-memory computers .  

Get Lubuntu 11.04


Learn about and discuss the Applications and Other Features included with Lubuntu!
Please read the release notes before you install.

Download


Please use the torrent download when possible to save our servers from being hammered on a release. The torrent should download faster than using the link below.
OR from here



I always have around an old computer : a Pentium II  @ 333MHz with 256 MB RAM ;
When I have some free time , on this machine , I test different Linux distros to see if they 
perform better than freeBSD . 
I still hope that some day I will be surprised by a new 
derivative of Ubuntu or Fedora ...