Search Results

Search found 422 results on 17 pages for 'marco demaio'.

Page 9/17 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • SQL INSERT performance omitting field names?

    - by Marco Demaio
    Does anyone knows if removing the field names from an INSERT query results in some performance improvements? I mean is this: INSERT INTO table1 VALUES (value1, value2, ...) faster for DB to be accomplished rather than doing this: INSERT INTO table1 (field1, field2, ...) VALUES (value1, value2, ...) ? I know it might be probably a meaningless performance difference, but just to know.

    Read the article

  • PHP explode and set to empty string the missing pieces

    - by Marco Demaio
    What's the best way to accomplish the following. I have strings in this format: $s1 = "name1|type1"; //(pipe is the separator) $s2 = "name2|type2"; $s3 = "name3"; //(in some of them type can be missing) Let's assume namen/typen are strings and they can not contain a pipe. Since I need to exctract the name/type separetly, I do: $temp = explode($s1, '|'); $name = $temp[0]; $type = ( isset($temp[1]) ? $temp[1] : '' ); Is there an easier (smarter whatever faster) way to do this without having to do isset($temp[1]) or count($temp). Thanks!

    Read the article

  • Javascript plugins design pattern like jQuery

    - by Marco Demaio
    Could someone write down a very simple basic example in javascript to conceptualize (and hopefully make me understand) how the jQuery plugin design pattern is done and how it works? I'm not interested in how creating plugin for jQuery (so no jQuery code here at all). I'm interested in a simple explanation (maybe with a bit of Javascript code) to explain how it is done the plugin concept. Plz do not reply me to go and read jQuery code, I tried, but I it's too complex, otherwise I would have not post a question here.

    Read the article

  • Javascript toFixed localized?

    - by Marco Demaio
    Do you know if toFixed is a localized function? I mean will this: var n = 100.67287; alert(n.toFixed(2)); show "100.67" on english US OS/browsers and "100,67" (with comma) on Italian OS/browsers (Italian or any other local system that uses comma as decimal separator). Thanks!

    Read the article

  • php - efficent way to get and remove first line in file

    - by Marco Demaio
    Hello, I have a script that each time is called gets the 1st line of a file. Each line is known to be exactly of the same length (32 alphanumerci chars) and terminates with a "\r\n". After getting the 1st line, the script removes it. Now I do in this way: $contents = file_get_contents($file)); $first_line = substr($contents, 0, 32); file_put_contents($file, substr($contents, 32 + 2)); //+2 because we remove also the \r\n Obvioulsy it works, but I was wondering if there could be a smarter (or more efficent) way to do this??? In my simple solution I basically read and rewrite all the file just to take and remove the 1st line. Thanks!

    Read the article

  • swapping or trashing with vast amounts of unmapped pagecache

    - by Marco
    I'm using kubuntu jaunty (i386 32bit), kernel 2.6.28-13-generic. I've 4Gb of RAM, of which only 3317Mb are seen by the system (I guess because of the 32bit system). I'm seeing that the pagecache utilization is continually growing, up to the point that the system is unusable (after a few days). This happens also when I don't do anything (all user applications closed and the bare minimum of services enabled). If enabled, the system starts to use swap space (using it all in the end). Even if swap is disabled, disk activity becomes continuous, with the system unresponsive. For example, right now the system is working (albeit a tad slow), with only Firefox and wing ide running, and I have 2Gb cached with only 45Mb mapped: $ free total used free shared buffers cached Mem: 3346388 3247328 99060 0 8416 2117980 -/+ buffers/cache: 1120932 2225456 Swap: 2144668 519448 1625220 $ cat /proc/meminfo MemTotal: 3346388 kB MemFree: 97128 kB Buffers: 7872 kB Cached: 2120224 kB SwapCached: 413860 kB Active: 2304596 kB Inactive: 865984 kB Active(anon): 2279168 kB Inactive(anon): 830236 kB Active(file): 25428 kB Inactive(file): 35748 kB Unevictable: 32 kB Mlocked: 32 kB HighTotal: 2492940 kB HighFree: 5456 kB LowTotal: 853448 kB LowFree: 91672 kB SwapTotal: 2144668 kB SwapFree: 1625244 kB Dirty: 84 kB Writeback: 0 kB AnonPages: 629304 kB Mapped: 45768 kB Slab: 45600 kB SReclaimable: 21756 kB SUnreclaim: 23844 kB PageTables: 4468 kB NFS_Unstable: 0 kB Bounce: 0 kB WritebackTmp: 0 kB CommitLimit: 3817860 kB Committed_AS: 3735020 kB VmallocTotal: 122880 kB VmallocUsed: 9352 kB VmallocChunk: 66600 kB HugePages_Total: 0 HugePages_Free: 0 HugePages_Rsvd: 0 HugePages_Surp: 0 Hugepagesize: 4096 kB DirectMap4k: 16376 kB DirectMap4M: 888832 kB If I try to drop the caches, little happens: # sync ; echo 3 > /proc/sys/vm/drop_caches ; free total used free shared buffers cached Mem: 3346388 3220580 125808 0 3020 2100600 -/+ buffers/cache: 1116960 2229428 Swap: 2144668 519356 1625312 Right now I've vm.swappiness = 5, but I've tried also with 0 and 1 (without noticeable differences). I've also tried vm.vfs_cache_pressure = 50 and 150 (again, no differences). As I said the pagecache eats all memory even with swapping turned off. What is happening? How to avoid this?

    Read the article

  • Bypassing Router's DNS Settings

    - by Ramon Marco Navarro
    Is there a way to bypass my ISP provided CPE/router's DNS settings? I'd like to use OpenDNS but I am unable to access the administrator acount of the CPE. I tried logging in using the default passwords (admin/admin, admin/1234, etc) to no avail. I found out later that the admin password is generated using a generator where you input the CPE's MAC address. I tried emailing the manufacturer of the CPE (Huawei, the CPE is Huawei BM625) and my ISP but they aren't replying. I also saw similar queries (lots of them!) at Huawei's forums, without a single reply. So as a last resort, I'd like to know a way to bypass the CPE's DNS settings. My subscription is for a WiMAX service. I'm using Windows 7 and have already set the DNS settings for the Local Area Connection. But I still am not seeing the "You are already using OpenDNS" text at OpenDNS's site. And when explicitly using the OpenDNS servers I still seem to get 208.69.38.150 rather than the expected 208.69.38.160: nslookup www.opendns.com. 208.67.222.222 Server: resolver1.opendns.com Address: 208.67.222.222 Non-authoritative answer: Name: www.opendns.com Address: 208.69.38.150

    Read the article

  • Windows Clients: Windows or Linux Domain Controller?

    - by Ramon Marco Navarro
    I'm planning to set up a domain controller for our small computer laboratory. I'm a little confused as to what operating system to use for our domain controller. What's in the lab: The lab has 25 units running a mix of Windows 7 and Windows XP. The domain controller will only have 2GB of RAM running a C2D E7200. (Is this enough?) What we want: The Domain Controller will also be running a git server. The Domain Controller will also be used as a general development machine (mostly Java, PHP). A way to centralize the updates for the windows clients, so that they won't have to download the same patches from the remote site. The machines would just query them from the local domain controller and get the updates from there. Our head recommended that I virtualize a Windows Server 2008 system under a Linux host and use the former as a domain controller and the latter for development or the other way around. A comparison of the advantages and disadvantages of using a Linux distribution or Windows Server 2008 in this situation would also be appreciated. As you may have noticed by now, I'm kinda new to setting up a domain so I hope you guys will be able to help me. Thank you.

    Read the article

  • Convert to WAN port

    - by Ramon Marco Navarro
    I have a ADSL2+ Modem/Router. Is it possible to set one out of four of the LAN ports as a WAN port? If yes, how? The brand/model is: Prolink H9200P. I already contacted Prolink about this and the site said to wait for one business day. But I'm still asking here just in case someone could answer faster than Prolink. Thank you.

    Read the article

  • Windows XP Installation issue - cannot find hard disk

    - by Marco
    A friend of mine gave me a laptop with Windows 8 installed and nothing else. I don't like it so I am trying to remove it by installing Windows XP. I have a windows XP installation CD that I have used before and worked fine, but didn't work when I tried to install it on the Windows 8 machine. It keeps telling me I don't have a drive to install to. Then I log into Windows 8 again and install check partitions. I found 2 and tried to make a new one but it will only let me make one of 69mb. Next, I tied to find a way to go back to XP with BCD install and try to set the boot loader for XP but it wasnt there. Somehow I deleted the bootloader for Windows 8 and now it asks me for a recovery tool for media. I am not familiar with the laptop specs, but it is a Toshiba with about 250GB storage, and above 1GHz processor.

    Read the article

  • Windows 2003 Cluster: Failover Delay

    - by Ramon Marco Navarro
    I am testing the failover policies of our test failover cluster system. When I shutdown the node who is currently controlling the cluster (NODE1), it takes about 2 mins and 40 seconds before the next node on the preferred list (NODE2) takes control of the cluster. I tried changing the looksAlive and isAlive interval to 5000ms to all resources, but that didn't help. Looking at the Event Viewer of the remaining nodes, it shows that it was almost instantly detected that NODE1 was down. But it took another ~2:40 minutes for it to be removed from the live cluster list and for NODE2 to take over. Is there anyway of changing or shortening this "failover delay"? This is the setup of the cluster: (1) One ClusterDC connected to the public network (3) Three nodes running Win2003 with a quorum type of MNS Private network is connected to network hub ________________ _________________ (ClusterDC)=------=| |=------=(Node1)=------=| | |Public Network|=------=(Node2)=------=|Private Network| | (Switch) |=------=(Node3)=------=| (Hub) | ---------------- -----------------

    Read the article

  • AAC Sample Rate and Bit Rate for High Quality Audio?

    - by marco.ragogna
    What are the AAC Sample Rate and Bit Rate settings to set in order to encode an audio track with a quality comparable to MP3 320kbps? I need to backup a DVD movie, the default settings for AAC are Bitrate (KB/s) 128 Sample Rate (HZ) 44100 should I set Bitrate (KB/s) 320 Sample Rate (HZ) 48000 or the default are already good?

    Read the article

  • Agile sysadmin and devops - How to accomplish?

    - by Marco Ramos
    Nowadays, agile systems adminitration and devops are some of the most trending topics regarding systems administration and operations. Both these concepts are mainly focused on bridging the gap between operations/sysadmins and the projects (developers, business, etc). Even if you never heard of the devops concept, I'm sure that this topic is your concern too. So, what tools and techniques do you use to accomplish devops in you companies? I'm particularly interested in topics like change management, continous integration and automatization, but not only. Please share your thoughts. I'm looking forward to read your answers/opinions :)

    Read the article

  • Hotfix entries in event log

    - by Marco Shaw
    Server 2008/2008 R2 I'm trying to remotely monitor these servers to watch the progress of hotfixes being installed. I was able to find this in Server 2003/2003 R2: -Log: System -Source: NtServicePack It seems the above event is written when every hotfix is installed. I can't seem to find a comparable entry in Server 2008/2008 R2 though. Is there anything similar that I can easily monitor for remotely?

    Read the article

  • Browsing mapped network drives in Aptana Studio - Windows 7

    - by Marco
    I've recently started using Windows 7 (64-bit) at work, but after installing Aptana like usual, and mapping my network folders like I always have, Aptana shows the mapped drives, but with a red X on the drive icon. Using the native windows explorer I can browse the drives fine, and I don't need to login. If it matters the mapped drives are hosted on both Windows and Linux servers. Any ideas on what to do? My googling is drawing blanks.

    Read the article

  • Convert WAV to PCM(wav)

    - by Marco
    Hi, I'm looking for a small PCM converter tool which I can access by Dos-Console. I have any wave-files and need always this output: PCM 44,1k, 16bit, Mono Is there any program for this? Thx 4 answers

    Read the article

  • Shinken - Anyone using it?

    - by Marco Ramos
    I've recently discovered Shinken, which a new implementation of Nagios using python. Shinken "divides" Nagios in 5 different types of agents, each one performing separated tasks. I haven't tried it yet but for what I've seen the whole architecture idea seems great to me (it works the Unix way: one process, one task), but the project seems a little "green" yet. So, has anyone tried Shinken? What's your opinion?

    Read the article

  • Failed Administrator login on WSO2 IS with external OpenLDAP

    - by Marco Rivadeneyra
    I have an installation of WSO2 Identity Server and I'm trying to make it work with an external OpenLDAP instance I have followed this guide: http://wso2.org/project/solutions/identity/3.2.3/docs/user-core/admin_guide.html#LDAP For the read-only mode. But when I try to log-in I get a failed login and the following error on the console: TID: [0] [WSO2 Identity Server] [2012-08-10 17:10:25,493] WARN {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - Failed Administrator login attempt 'john[0]' at [2012-08-10 17:10:25,0493] from IP address 127.0.0.1 {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} Full log: http://pastebin.com/pHUGXBqv My configuration file looks as follows: <UserManager> <Realm> <Configuration> <AdminRole>admin</AdminRole> <AdminUser> <UserName>john</UserName> <Password>johnldap</Password> </AdminUser> <EveryOneRoleName>everyone</EveryOneRoleName> <!-- By default users in this role sees the registry root --> <ReadOnly>true</ReadOnly> <MaxUserNameListLength>500</MaxUserNameListLength> <Property name="url">jdbc:h2:repository/database/WSO2CARBON_DB</Property> <Property name="userName">wso2carbon</Property> <Property name="password">wso2carbon</Property> <Property name="driverName">org.h2.Driver</Property> <Property name="maxActive">50</Property> <Property name="maxWait">60000</Property> <Property name="minIdle">5</Property> </Configuration> <UserStoreManager class="org.wso2.carbon.user.core.ldap.LDAPUserStoreManager"> <Property name="ReadOnly">true</Property> <Property name="MaxUserNameListLength">100</Property> <Property name="ConnectionURL">ldap://192.168.81.144:389</Property> <Property name="ConnectionName">cn=admin,dc=example,dc=com</Property> <Property name="ConnectionPassword">admin</Property> <Property name="UserSearchBase">ou=People,dc=example,dc=com</Property> <Property name="UserNameListFilter">(objectClass=inetOrgPerson)</Property> <Property name="UserNameAttribute">uid</Property> <Property name="ReadLDAPGroups">false</Property> <Property name="GroupSearchBase">ou=Groups,dc=example,dc=com</Property> <Property name="GroupSearchFilter">(objectClass=groupOfNames)</Property> <Property name="GroupNameAttribute">uid</Property> <Property name="MembershipAttribute">member</Property> </UserStoreManager> <AuthorizationManager class="org.wso2.carbon.user.core.authorization.JDBCAuthorizationManager"></AuthorizationManager> </Realm> I followed this guide to configure my LDAP server up to Loggging: https://help.ubuntu.com/12.04/serverguide/openldap-server.html Could you suggest what might be wrong? The LDAP log is available at: http://pastebin.com/T9rFYEAW

    Read the article

  • Does exists a software that act as DHCP service?

    - by marco.ragogna
    I need to configure a network made by a simple old hub with 24-ports a server and some clients. Both clients and server has Windows XP or later. If all clients has the DCHP service enabled does exists a software that, installed on the server, assigns automatically to the clients an IP based on a predefined range?

    Read the article

  • SELinux vs. AppArmor vs. grsecurity

    - by Marco
    I have to set up a server that should be as secure as possible. Which security enhancement would you use and why, SELinux, AppArmor or grsecurity? Can you give me some tips, hints, pros/cons for those three? AFAIK: SELinux: most powerful but most complex AppArmor: simpler configuration / management than SELinux grsecurity: simple configuration due to auto training, more features than just access control

    Read the article

  • 2 pass encoding or not?

    - by marco.ragogna
    I would like to do a backup of some movies on DVD with File Factory. In the output setting, by default the option 2 pass encoding is disabled. Do I need to enable it for better quality and does it worth?

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >